Q: How can I modify the duration of LISTSERV login cookies?

By Jacob Haller
Senior Support Engineer, L-Soft

By default, when a user logs in to the LISTSERV web interface, the web browser stores a login cookie. As long as the cookie is present, the web interface does not require the user to log in again. However, some LISTSERV sites may require login cookies to expire after a specific amount of time. This tip shows how you can modify the expiration time on a per-user or sitewide basis.

User Preferences

Individual users can set their login cookie preferences by clicking on Preferences under the "Subscriber Options" section of the navigation menu on the left side of the web interface.

Find the Login Cookie Expiration setting, and select the desired cookie duration. Selecting "Session" means that the cookie will expire when the browser session is closed.

Site Preferences

LISTSERV site administrators may set sitewide cookie expiration preferences. Under the "Server Administration" section, select Web Templates.

In the Template Name box, enter DEFAULTS and click the Search button to find the "Defaults - Site Preferences" template.

Click on the name of the template, and look for the following section:

+******************** Login Cookie Expiration ********************
+* SESSION - end of browser session
+* m - minutes (60m)
+* d - days (30d)
+* w - weeks (1w)
+* M - months (12M)
+* y - years (2y)
+* 0 - never expires
+* Defines expiration but allows users to change setting through personal preferences
+* Defines expiration and forces all users to use this setting (undefined by default)
+* Disables cookie-based logins (not recommended)

By default, COOKIE_EXPIRATION is set to 0, which means that cookies never expire. The site administrator may override it by setting an expiration time in minutes, days, weeks, months or years. The new default setting will apply to all users who have not set their own preferences via the Preferences screen. To override user settings, you can also set an expiration time in the EXPIRECOOKIE_OVERRIDE setting. That setting applies to everyone regardless of any user preferences that may be set.

Next Steps

Do you like this type of content? Subscribe to the LISTSERV at Work newsletter.

LISTSERV is a registered trademark licensed to L-Soft international, Inc.

See Guidelines for Proper Usage of the LISTSERV Trademark for more details.

All other trademarks, both marked and unmarked, are the property of their respective owners.