Conversation
client_list struct; no functional change intended. * modules/aaa/mod_auth_digest.c (struct hash_table): Add next_id field; note that all access must be inside client_lock. (client_id_counter): Remove global. (initialize_tables): Seed client_list->next_id rather than allocating and seeding client_id_counter. (add_client): Remove, merging into... (client_generate): ...here; issue the id from client_list->next_id inside client_lock rather than via atomics, and log allocation failure. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
* modules/aaa/mod_auth_digest.c (client_id_t): Widen to apr_uint64_t. (CLIENT_ID_MAX): New. (initialize_tables): Cap the seed at CLIENT_ID_MAX. (client_generate): Issue ids in 1..CLIENT_ID_MAX. (client_exists, client_update_nonce, client_generate): Log ids with APR_UINT64_T_FMT. (parse_digest_header): Parse the opaque with apr_strtoi64(), returning INVALID if it is not in 1..CLIENT_ID_MAX. (authenticate_digest_user): Remove the now-unreachable invalid opaque check (AH01787); mention an invalid opaque in AH01782. (ltox): Rename to... (client_id_to_opaque): ...this; format with APR_UINT64_T_HEX_FMT. (note_digest_auth_failure): Update callers. * test/modules/aaa/test_001_challenge_response.py (test_digest_013_invalid_opaque): Accept AH01782 as well as AH01787. * test/modules/aaa/test_003_nccheck.py (test_digest_035_out_of_range_opaque_is_not_truncated): Try opaques 2^32 and 2^64 above the live id. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
add_client()intoclient_generate()