Let Your .local Users Log Into Outlook Web App 2010 By Using Their Email Addresses
I’m sure that the .local Top Level Domain (TLD) must be by far the most commonly used domain name out there. And all users in a .local TLD will have a User Principal Name (UPN) in the form firstname.lastname@example.org. It’s quite common for users to forget it, though, and try to use their email addresses (e.g. email@example.com) in circumstances where they should actually be using their UPN. Often, you will hear of people trying to log into OWA by using their email address, and being denied access. Because, of course, IIS is looking for the UPN.
What I have described here is a little modification (made at your own risk) to the OWA 2010 Forms-Based Authentication (FBA) logon page that will automatically change the domain.local to domain.com (or domain.org, or domain.co.uk, or whatever you wish). To make the change, locate the logon.aspx file in your
C:\Program Files\Microsoft\Exchange Server\V14\ClientAccess\Owa\auth
folder. Before doing anything else, make a backup copy.
Open the file in Notepad, and search (CTRL-F) for the text <form
You should find it at the start of a very long line that begins like this (I’m only showing the beginning):
<form action=”/owa/auth.owa” method=”POST” name=”logonForm” ENCTYPE=”…
The first change to make is to add an onsubmit attribute, like this:
<form onsubmit=”checkDomain()” action=”/owa/auth.owa” method=”POST” name=”…
Then, just before this, on the previous line, insert the following text:
var x = document.getElementById(“username”);
var y = x.value;
y = y.toLowerCase();
y = y.replace(“@yourdomain.local”, “@yourdomain.com”);
x.value = y;
Of course, you will need to supply your own domain names in the appropriate place.
Save the file back, and you’re finished.
Please remember – like all OWA mods, there is every chance it will be lost when you apply a service pack or rollup, since the files tend to get replaced with newer version. You will need to check that the changes are still there.