Skip to content

Conversation

@Alexhuszagh
Copy link
Owner

This patches a lot of the wrappers in AsciiStr being marked as safe but not being safe except within the context, using raw pointer dereferences without local bounds checks.

This is extensively documented in aldanor#37:
aldanor#37

AsciiStr has been re-written as a result, and unsafe functions marked as safe have been either converted to safe variants where the compiled checks can be ellided or marked as unsafe so the caller knows to upholds the safety invariants.

This patches a lot of the wrappers in `AsciiStr` being marked as safe but not being safe except within the context, using raw pointer dereferences without local bounds checks.

This is extensively documented in aldanor#37:
    aldanor#37

`AsciiStr` has been re-written as a result, and unsafe functions marked as safe have been either converted to safe variants where the compiled checks can be ellided or marked as unsafe so the caller knows to upholds the safety invariants.
@Alexhuszagh Alexhuszagh added the A-sec Related to unsoundness/security issues. label Oct 31, 2024
@Alexhuszagh Alexhuszagh added this to the 0.2.2 milestone Oct 31, 2024
@Alexhuszagh Alexhuszagh self-assigned this Oct 31, 2024
@Alexhuszagh Alexhuszagh linked an issue Oct 31, 2024 that may be closed by this pull request
@Alexhuszagh Alexhuszagh merged commit 57bf987 into main Oct 31, 2024
16 checks passed
@Alexhuszagh Alexhuszagh deleted the issue_2 branch October 31, 2024 04:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-sec Related to unsoundness/security issues.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Potential unsoundnesses (not yet determined) with use of unsafe

2 participants