aboutsummaryrefslogtreecommitdiff
path: root/src/microhttpd/digestauth.c
Commit message (Collapse)AuthorAge
* digestauth: use pre-calculated URI length to avoid stop at first binary zeroEvgeny Grin (Karlson2k)2022-06-23
|
* digestauth: use size_t for counting headersEvgeny Grin (Karlson2k)2022-06-23
|
* digestauth: added check whether arguments specified in the right orderEvgeny Grin (Karlson2k)2022-06-23
|
* digestauth: removed now unused do-while scopeEvgeny Grin (Karlson2k)2022-06-22
|
* Fixed check for URL match to handle URLs with binary zeroEvgeny Grin (Karlson2k)2022-06-22
|
* digest_auth_check_all(): simplified, improved readabilityEvgeny Grin (Karlson2k)2022-06-22
| | | | | | | | | | | Added check for too long nonce (the size is know in advance, no need to try other check if nonce size is wrong); Used caseless match more 'qop' value (as required by RFC), too long 'qop' values reject early, added special result value for wrong qop; Reject early with too long 'nc' value; Reject early with wrong response size (the size is know in advance, no need to make CPU-intensive hash calculations if size if incorrect); Added special return value is any parameter is too large to be processed
* MHD_parse_arguments_(): refactored, allow cls for the callbackEvgeny Grin (Karlson2k)2022-06-22
|
* Fixed wrong usage of maximum client nonce size as maximum size of server nonceEvgeny Grin (Karlson2k)2022-06-07
| | | | This also saves some RAM for nonce-nc map array
* digestauth: avoid repetitive calculations of some strings' lengthEvgeny Grin (Karlson2k)2022-06-06
|
* Simplified Digest Auth code by using the new string processing functionsEvgeny Grin (Karlson2k)2022-06-06
|
* Fixed 'int' instead of 'MHD_Result'Evgeny Grin (Karlson2k)2022-05-31
|
* authentication: reworked header parsingEvgeny Grin (Karlson2k)2022-05-31
| | | | | | | | | Added single function to parse all enabled authentication schemes header strings. The parsing result is cached and reused thus avoiding repetitive header parsing. The new function correctly "unquotes" values (backslashes are removed) as required by RFC.
* digestauth: reworked support for multiple digest algorithmsEvgeny Grin (Karlson2k)2022-05-23
|
* Created digestauth.h headerEvgeny Grin (Karlson2k)2022-05-20
|
* digestauth: simplified overflow checkEvgeny Grin (Karlson2k)2022-05-16
|
* Added two new public functions for digest authenticationEvgeny Grin (Karlson2k)2022-05-13
|
* digestauth: added detection for possibly fabricated noncesEvgeny Grin (Karlson2k)2022-05-13
|
* digestauth: cosmeticsEvgeny Grin (Karlson2k)2022-05-13
|
* digestauth: fixed wrong results of client data checkEvgeny Grin (Karlson2k)2022-05-13
| | | | | | | | Stale 'nonce' from client was reported as either 'INVALID_NONCE' or just as 'MHD_NO'. Now it is always reported as 'INVALID_NONCE". Unfortunately wrong 'nonce' is reported as 'INVALID_NONCE' as well and it cannot be fixed with current API.
* digestauth: always use master daemon onlyEvgeny Grin (Karlson2k)2022-05-06
|
* Added one more fallback for unique nonce generationEvgeny Grin (Karlson2k)2022-05-06
|
* digestauth: added check for valid nonce format in the nonce-nc mapEvgeny Grin (Karlson2k)2022-05-06
| | | | This is required to prevent strlen() runaway.
* digestauth: added two more assertsEvgeny Grin (Karlson2k)2022-05-06
|
* digestauth: fixed logic of free nonce-nc slot detectionEvgeny Grin (Karlson2k)2022-05-06
|
* Fixed additional wrong (inverted) assertsEvgeny Grin (Karlson2k)2022-05-05
|
* Fixed wrong (inverted) assertsEvgeny Grin (Karlson2k)2022-05-05
|
* digestauth: re-used static functionEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: added management of nonce-nc map array slotsEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: additional static function for code re-useEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: additional macros for readabilityEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: use mseconds for timestampEvgeny Grin (Karlson2k)2022-05-04
| | | | The clash of nonces is lower with higher timestamp resolution
* digestauth: increased timestamp to 48 bitsEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: added run-time checks for algo valueEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: additional assertEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: changed type of varEvgeny Grin (Karlson2k)2022-05-04
|
* digestauth: use 7 bit shift for fast "hash"Evgeny Grin (Karlson2k)2022-05-04
| | | | | As only ASCII printable chars are used for "nonce", the highest bit is always zero.
* check_nonce_nc(): sorted checks according to probabilityEvgeny Grin (Karlson2k)2022-05-01
| | | | | The code should be more readable and it should give very minor performance improvement.
* check_nonce_nc(): additionally improved readability, fixed commentsEvgeny Grin (Karlson2k)2022-05-01
|
* check_nonce_nc(): fixed missing set of the bit for the old 'nc' valueEvgeny Grin (Karlson2k)2022-05-01
| | | | | When 'nc' values are increased sequentially, the bit for the old 'nc' value was not set.
* check_nonce_nc(): moved 'nc' overflow check out of mutex lockEvgeny Grin (Karlson2k)2022-05-01
|
* check_nonce_nc(): improved readability, fixed commentsEvgeny Grin (Karlson2k)2022-05-01
|
* check_nonce_nc(): simplifiedEvgeny Grin (Karlson2k)2022-05-01
| | | | | If 'nc' is not valid, then 'nonce' is always stale as 'nonce' validity has been checked already.
* digestauth: when checking 'nc' reuse always check nonce match firstEvgeny Grin (Karlson2k)2022-05-01
| | | | | | While the validity of nonce itself was already checked, it could be stale nonce, so let's make sure that re-use of 'nc' is limited to the same nonce only.
* digestauth: do not add nonce from client, if it was not generated by MHDEvgeny Grin (Karlson2k)2022-04-30
|
* digestauth: added dedicated function for adding the new noncesEvgeny Grin (Karlson2k)2022-04-30
|
* check_nonce_nc(): use already known nonce size, avoid size recalculationEvgeny Grin (Karlson2k)2022-04-30
|
* digestauth: moved "hash" calculation to separate functionEvgeny Grin (Karlson2k)2022-04-28
|
* Fixed compiler warnings of implicit casting, which could change the valueEvgeny Grin (Karlson2k)2022-04-27
|
* Added _MHD_EXTERN to the all public functions definitionsEvgeny Grin (Karlson2k)2022-04-18
| | | | | Previously it was inconsistent, some function definitions used _MHD_EXTERN, while other definitions was used without _MHD_EXTERN.
* Refactoring: different types for response and request headersEvgeny Grin (Karlson2k)2022-04-17
| | | | | Request headers are always read-only (const char *), while response headers are modifiable. Should help with catching errors in code.