Skip to content

CensysUnauthorizedException: 403 (Forbidden): Your user does not have permission to define specific fields. #524

@cloudjunky

Description

@cloudjunky

Describe the bug
If you execute search_certs.py you get the following error;

censys.common.exceptions.CensysUnauthorizedException: 403 (Forbidden): Your user does not have permission to define specific fields.

And as the 403 suggests if you strip out the fields the example works;

from censys.search import CensysCerts

c = CensysCerts()


# Single page of search results
query = c.search(
    "parsed.subject.country: AU",
    sort=["parsed.issuer.organization", "parsed.subject.postal_code"],
)
hits = query()
print(hits)

# Multiple pages of search results
query = c.search(
    "parsed.subject.country: AU",
    sort=["parsed.issuer.organization", "parsed.subject.postal_code"],
    pages=2,
    per_page=5,
)
for hits in query:
    for hit in hits:
        print(hit)

# View all results
query = c.search(
    "parsed.subject.country: AU",
    sort=["parsed.issuer.organization", "parsed.subject.postal_code"],
    pages=2,
    per_page=5,
)
print(query.view_all())

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions