[Mono-bugs] [Bug 387526] New: System.Web.Configuration.RoleManagerSection. CookieTimeout uses incorrect time units

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed May 7 01:28:17 EDT 2008


https://bugzilla.novell.com/show_bug.cgi?id=387526


           Summary: System.Web.Configuration.RoleManagerSection.CookieTimeou
                    t uses incorrect time units
           Product: Mono: Class Libraries
           Version: SVN
          Platform: x86
        OS/Version: Linux
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: Sys.Web
        AssignedTo: mhabersack at novell.com
        ReportedBy: ivan at chimerical.com.au
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---


System.Web.Configuration.RoleManagerSection.CookieTimeout maps the config
section as days, and not minutes.
Althought the default is set correctly in minutes, its configuration property
doesn't specify a converter, and uses the timespan default (days).

Proposed fix:

Index: System.Web.Configuration_2.0/RoleManagerSection.cs
===================================================================
--- System.Web.Configuration_2.0/RoleManagerSection.cs  (revision 102698)
+++ System.Web.Configuration_2.0/RoleManagerSection.cs  (working copy)
@@ -64,7 +64,10 @@
                                                                         
CookieProtection.All);
                        cookieRequireSSLProp = new ConfigurationProperty
("cookieRequireSSL", typeof (bool), false);
                        cookieSlidingExpirationProp = new ConfigurationProperty
("cookieSlidingExpiration", typeof (bool), true);
-                       cookieTimeoutProp = new ConfigurationProperty
("cookieTimeout", typeof (TimeSpan), TimeSpan.FromMinutes (30));
+                       cookieTimeoutProp = new ConfigurationProperty
("cookieTimeout", typeof (TimeSpan), TimeSpan.FromMinutes (30),
+                                                                      
PropertyHelper.TimeSpanMinutesOrInfiniteConverter,
+                                                                      
PropertyHelper.PositiveTimeSpanValidator,
+                                                                      
ConfigurationPropertyOptions.None);
                        createPersistentCookieProp = new ConfigurationProperty
("createPersistentCookie", typeof (bool), false);
                        defaultProviderProp = new ConfigurationProperty
("defaultProvider", typeof (string), "AspNetSqlRoleProvider");
                        domainProp = new ConfigurationProperty ("domain",
typeof (string), "");
@@ -179,4 +182,4 @@
        }
 }

-#endif
+#endif


-- 
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list