Fixed
Details
Details
Assignee
Scott Cantor
Scott CantorReporter
voetsjoeba+protectnetwork@gmail.com
voetsjoeba+protectnetwork@gmail.comComponents
Fix versions
Affects versions
Created May 2, 2016 at 3:52 PM
Updated June 29, 2016 at 4:22 PM
Resolved May 11, 2016 at 2:04 AM
While running the memcached server in verbose mode to inspect the traffic being sent to it from Shibboleth, I noticed that MemcacheStorageService::deleteContext does not correctly delete the individual elements from the context.
Below is sample memcached traffic generated by a call to MemcacheStorageService::deleteContext() to delete a session context with a single key, "session":
<28 get myprefix:_f9adc362f039c2d354da22960d9ad3bf >28 sending key myprefix:_f9adc362f039c2d354da22960d9ad3bf >28 END <28 delete myprefix:_f9adc362f039c2d354da22960d9ad3bfsession >28 NOT_FOUND <28 delete myprefix:_f9adc362f039c2d354da22960d9ad3bf >28 DELETED
The context map correctly lists the "session" field, but there is a ":" missing between the context ID and the keys to be deleted:
for (list<string>::const_iterator iter = contents.begin(); iter != contents.end(); ++iter) { string final_key = map_name + *iter; deleteMemcache(final_key.c_str(), 0); }
Session data that otherwise would have been deleted therefore stays present on the memcached host, causing unnecessary resource pressure.