Subscribe to Windows IT Pro
November 24, 2003 12:00 AM

Forms-Based Authentication in OWA 2003

Reduce OWA's security vulnerabilities
Windows IT Pro
InstantDoc ID #40754
Rating: (1)

The next scenario we'll look at illustrates what happens when a user doesn't perform any operation within a specified window of time. The next operation the user tries to perform will present the logon page. Before I explain how this process occurs, it's important to note that the front-end server maintains knowledge of three symmetric keys—the current key and the previous two keys. In fact, there are two sets of these three keys—one set for Public access and one set for Trusted access. The reason for having two sets is to provide different timeouts for accessing OWA through a public computer (e.g., a kiosk) and from a private location such as a home office.

You can control the desired timeout values by modifying the REG_DWord values PublicClientTimeOut and TrustedClientTimeOut in the HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MsExchangeWeb\OWA registry subkey on the front-end server. These values are expressed in minutes, with a default timeout of 15 minutes for a public client and 1440 minutes (24 hours) for a private client.

The server regenerates a symmetric key at a frequency of half the desired timeout value, which means that the actual timeout will occur between 1 and 1.5 times the desired timeout value. For example, let's say you set a timeout value of 30 minutes. Every 15 minutes, the server will generate a new key and, therefore, a key will exist on the server for a maximum of 45 minutes.

When the ISAPI filter creates the cookie (see Scenario 1, Step 7) and adds the encrypted base64 credentials to it, the filter also adds the current key number and session ID. We can see this in the cookie header that Figure 4 shows. This header came from a network trace for Step 7.

The cadata string starts with the index number of the key that was used for the encryption and will be a value of 0, 1, or 2. A value of 2 indicates the current key. In the example that Figure 4 shows, the value 1 means the previous key was used. Let's look at the following scenario to see how timeouts work.

Scenario 2. In the second scenario, a user remains idle for longer than the timeout period, then tries to open the Calendar folder. This action generates an HTTP request to the server for http://fe/exchange/user/calendar?cmd=contents.

  1. The ISAPI filter intercepts the request and determines whether a cookie is attached. In this case, the request has a cookie.


  2. The filter extracts from the cookie the index number of the symmetric key used to encrypt the data. Note that this isn't the actual symmetric key, just the index number of the key.


  3. The filter retrieves the current key associated with this index number and uses it to decrypt the data. Remember that the server is maintaining three keys and generates a new one after each key interval. Thus, the keys associated with each index position change as well.


  4. In this case, decryption fails because the key that's associated with the index position is no longer the same key that was in that position when encryption originally occurred.


  5. The ISAPI filter strips off the cookie and passes the HTTP request to the Exchange server.


  6. We're now in the same situation as Scenario 1, Step 1.

The two scenarios I've presented here will help you understand the authentication process and how forms-based technology can help secure this process. Be sure to read the Web-exclusive sidebar "Forms-Based Authentication: Problems and Points Worth Noting" (http://www.winnetmag.com/microsoftexchangeoutlook, InstantDoc ID 40821) for a few caveats to remember when deploying the technology in your environment.

Moving Forward
Lack of a secure logoff method is one of the main stumbling blocks when corporations consider opening up Exchange to external access through OWA. Forms-based authentication goes a long way in mitigating this problem and should encourage more enterprises to embrace such a deployment.

Related Content:

ARTICLE TOOLS

Comments
  • redwraith94
    5 years ago
    Feb 24, 2007

    Or you can delete both cookies, and the index.dat file, this will clear stored usernames, and passwords:

    Microsoft recommends to delete cookies from the browser, 'usually' by closing the browser. However that doesn't work.

    You must delete the cookies, and 2 copies of Index.dat

    After deleting cookies navigate to:

    C:\\Documents and
    Settings\\%username%\\Cookies\\Index.dat

    And,

    C:\\Documents and Settings\\%username%\\Userdata\\Index.dat

    Make sure all instances of Internet explorer are closed.

    and delete both index.dat files. These are recreated the next time the browser is opened.

    So, for a user named 'me', it would be:

    C:\\Documents and Settings\\ME\\Cookies\\Index.dat

    And,

    C:\\Documents and Settings\\ME\\Userdata\\Index.dat

    If this process gives any errors, then make sure that all instances of the 'iexplore.exe' process are closed.

    Task Manager > Processes 'Tab'

You must log on before posting a comment.

Are you a new visitor? Register Here

advertisement

advertisement

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.