Bug 387254

Summary: kcookiejar misparses non-rfc2822 dates in cookies
Product: [Frameworks and Libraries] frameworks-kio Reporter: Andreas Schwab <schwab>
Component: generalAssignee: David Faure <faure>
Status: RESOLVED FIXED    
Severity: normal CC: kdelibs-bugs-null
Priority: NOR    
Version First Reported In: 5.32.0   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Andreas Schwab 2017-11-24 10:26:32 UTC
kcookiejar is using locale-aware Qt functions to parse the dates in cookies, which fails when running in a non-English locale.  It should instead use the C locale, so that the English month names are recognized.
Comment 1 Albert Astals Cid 2018-01-05 22:02:11 UTC
Git commit 75b2e3deebd42a3753fe2971a5f4a2a26edcab69 by Albert Astals Cid, on behalf of Andreas Schwab.
Committed on 05/01/2018 at 22:02.
Pushed by aacid into branch 'master'.

Properly parse dates in cookies when running in non-English  locale

Summary:
Use the C locale when parsing dates in cookies, since only English week
and month names are allowed

Reviewers: dfaure, #frameworks

Reviewed By: dfaure

Subscribers: anthonyfieroni, #frameworks

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D8983

M  +8    -3    src/ioslaves/http/kcookiejar/kcookiejar.cpp

https://commits.kde.org/kio/75b2e3deebd42a3753fe2971a5f4a2a26edcab69