[BUG] PydanticInvalidForJsonSchema error when requesting /docs or /redoc endpoints #725
Open
1 task done
Labels
bug
Something isn't working
Is there an existing issue for this?
Empire Version
5.9.5
Python Version
3.11.8
Operating System
Kali Rolling 2023.3
Database
MariaDB
Current Behavior
When requesting /docs (or /redoc), those endpoints 200 however the request for openapi.json is a 500. The following error output is generated by the server:
Expected Behavior
When requesting /docs, FastAPI Swagger UI loads without error showing API endpoints.
Steps To Reproduce
setup/install.sh
source .venv/bin/activate && ./ps-empire server
Anything else?
It appears the issue lies within the
empire.server.api.v2.shared_dto.CustomOptionSchema
class, particularly the methodscheck_value
andcheck_suggested_values
trigger the PydanticInvalidForJsonSchema error.https://github.com/BC-SECURITY/Empire/blob/main/empire/server/api/v2/shared_dto.py#L33
The 500 can be "fixed" by commenting the following lines of
empire/server/api/v2/shared_dto.py
and then you can access the /docs and /redoc endpoints without issues:Lines 35-43
The text was updated successfully, but these errors were encountered: