session cookie be too short.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@814334
13f79535-47bb-0310-9956-
ffa450edef68
Changes with Apache 2.3.3
+ *) mod_session_crypto: Sanity check should the potentially encrypted
+ session cookie be too short. [Graham Leggett]
+
*) mod_session.c: Prevent a segfault when session is added but not
configured. [Graham Leggett]
return res;
}
+ /* sanity check - decoded too short? */
+ if (decodedlen < (sizeof(apr_uuid_t) + ivSize)) {
+ ap_log_rerror(APLOG_MARK, APLOG_ERR, APR_SUCCESS, r, LOG_PREFIX
+ "too short to decrypt, skipping");
+ return APR_ECRYPT;
+ }
+
/* bypass the salt at the start of the decoded block */
decoded += sizeof(apr_uuid_t);
decodedlen -= sizeof(apr_uuid_t);