owasp-amass/amass · info
no matching organizations were found
Error message
no matching organizations were found
What it means
orgsWithSameNames queries the graph for Organizations matching any of the supplied names and returns the resulting entity slice. If the query succeeds but returns zero organizations, it wraps the empty result in this error so callers can distinguish 'no orgs at all with these names' from an actual lookup failure.
Source
Thrown at engine/plugins/support/org/match.go:204
}
}
}
var orgents []*dbt.Entity
for _, ident := range idents {
if edges, err := sess.DB().IncomingEdges(ctx, ident, time.Time{}, "id"); err == nil {
for _, edge := range edges {
if a, err := sess.DB().FindEntityById(ctx, edge.FromEntity.ID); err == nil && a != nil {
if _, ok := a.Asset.(*org.Organization); ok {
orgents = append(orgents, a)
}
}
}
}
}
if len(orgents) == 0 {
return nil, errors.New("no matching organizations were found")
}
return orgents, nil
}
View on GitHub (pinned to 79299dce87)
Solutions
- Expected for new entities: callers proceed to create the Organization
- Check that prior ingestions actually created name claims (CreateOrgNameClaim) for the target org
- Verify query-time name normalization matches claim-time normalization (genNormName)
- Test the same name directly via FindOrgByNameClaim to confirm graph state
Defensive patterns
Strategy: try-catch
Validate before calling
orgs, err := FindOrgByNameClaim(sess, name, src)
if err != nil {
// empty result — safe to create a new org
} Try / catch
if _, err := FindOrgByNameClaim(sess, o.Name, src); err != nil {
// not found: proceed with creation
} Prevention
- Expect empty results for new entities — branch on the error, don't panic
- Verify ingestion created name claims for orgs you expect to find
- Use identical normalization at claim time and query time
When it happens
Trigger: Called from existsAndSharesAncestorEntity or existsAndHasAncestorInSession with names (o.Name and o.LegalName) that no stored Organization claims — a successful DB query that simply found nothing.
Common situations: First-time ingestion of a brand-new company; names stored under different casing/punctuation than queried; name claims never created for legacy orgs; typo in Name/LegalName.
Understand the failure class
Background: EmptyResultError / "no results found": when an API or scraper succeeds but returns zero rows — this error's family across 9 libraries.
Related errors
- zero names provided in the Organization
- no matching org found
- missing the organization name
- failed to discover or create the Organization asset
- GLEIFSearchFuzzyCompletions: no results found
AI-assisted analysis of owasp-amass/amass@79299dce87 (2026-09-06).
Data as JSON: /api/errors/b604a57b1e6aaee2.
Report an issue: GitHub.