-
Notifications
You must be signed in to change notification settings - Fork 825
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set default pjsip_cred_info.auth_algorithm to PJSIP_AUTH_ALGORITHM_MD5 (
#4195) The new algorithm_type field in the pjsip_cred_info structure wasn't being defaulted to PJSIP_AUTH_ALGORITHM_MD5 as it should be. As a result if the user specified a data_type of PJSIP_CRED_DATA_DIGEST but didn't explicitly set algorithm_type, it was left at PJSIP_AUTH_ALGORITHM_NOT_SET which will caused authentication to fail. * pjsip_cred_info.auth_algorithm is now correctly defaulted to PJSIP_AUTH_ALGORITHM_MD5 when supplied via the pjsip_auth_lookup_cred and pjsip_auth_lookup_cred2 callbacks and via the pjsip_auth_clt_set_credentials, and pjsip_auth_create_digest functions. * pjsip_cred_info.auth_algorithm now defaults to PJSIP_AUTH_ALGORITHM_SHA256 for the pjsip_auth_create_digestSHA256 function. * Documentation was updated for those functions and callbacks to indicate the defaults. NOTE: The pjsip_auth_create_digest and pjsip_auth_create_digestSHA256 defaults are actually set in pjsip_auth_create_digest2 because those two functions are now deprecated wrappers that pass cred_info (which is a const) to pjsip_auth_create_digest2. The documentation for pjsip_auth_create_digest2 however, doesn't mention defaults on purpose because it's a generic function that handles multiple algorithms and we want users to specifify exactly what algorithms they want to use to avoid ambiguity. Resolves: #4194
- Loading branch information
Showing
3 changed files
with
58 additions
and
11 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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