shiro-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kalle Korhonen (JIRA)" <j...@apache.org>
Subject [jira] Resolved: (SHIRO-177) Wron SimpleCookie expires locale
Date Thu, 01 Jul 2010 06:25:50 GMT

     [ https://issues.apache.org/jira/browse/SHIRO-177?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Kalle Korhonen resolved SHIRO-177.
----------------------------------

    Fix Version/s: 1.0.1
                   1.1.0
       Resolution: Fixed

Fixed both in 1.0.1 and 1.1.0 branches but since there's a workaround (see the duplicate issue),
not critical enough to alone warrant the release of Shiro 1.0.1

> Wron SimpleCookie expires locale
> --------------------------------
>
>                 Key: SHIRO-177
>                 URL: https://issues.apache.org/jira/browse/SHIRO-177
>             Project: Shiro
>          Issue Type: Bug
>          Components: Session Management
>    Affects Versions: 0.9-RC1, 0.9, 1.0.0, 1.0.1, 1.1.0, Incubation
>         Environment: Windows XP, Jetty
>            Reporter: Vasily Shestkov
>            Assignee: Kalle Korhonen
>             Fix For: 1.0.1, 1.1.0
>
>
> SimpleCookie.toCookieDate method to format cookie uses default locale. My default locale
ru_RU. When browser receive cookie with expires formatted in non en_US locale, browser set
cookie expires=session.
> Resolutiojon of this trouble is: 
>     private static String toCookieDate(Date date) {
>         TimeZone tz = TimeZone.getTimeZone(GMT_TIME_ZONE_ID);
>         DateFormat fmt = new SimpleDateFormat(COOKIE_DATE_FORMAT_STRING, Locale.US);
>         fmt.setTimeZone(tz);
>         return fmt.format(date);
>     }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message