AdaCore / AdaCore/aws

Default_Unexpected_Exception_Handler may leak sensitive data

Open
#334 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ada
Stars
162
Forks
45
PR merge metrics
No merged PRs in 30d

Description

If a file named 500.tmplt does not exist, AWS.Server.Default_Unexpected_Exception_Handler will send the traceback from Ada.Exceptions.Exception_Information to clients, leaking information about memory offsets and program information that may be useful to an attacker trying to build an exploit.

See CWE-209 for more information about this class of vulnerability.

I believe this is unsafe default behavior and Default_Unexpected_Exception_Handler should be modified to only send Exception_Information to Log and/or Standard_Error and return a generic 500 Internal Server Error to clients.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at AWS.Server.Default_Unexpected_Exception_Handler and inspect how it handles a missing 500.tmplt file. Verify where Ada.Exceptions.Exception_Information is sent, then ensure exception details go only to Log and/or Standard_Error while clients receive a generic 500 Internal Server Error.

Written by the indexing model from the issue text.

Assessment

Domain
backend, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.