I spent the last week or so setting up Forms Authentication on Sharepoint 2007 (MOSS 2007) and the SQL Membership provider. There are a couple of good blog posts out there, but judging from the number of comments, this configuration is still frought with potential errors. Here's my summary, list of resources, and the new findings that weren't documented anywhere else.
CRITICAL STEP: In the web.config file Membership configuration, there is an attribute called 'applicationName', which is associated with any users you create from that web site.
<
Since I had used 'MyAppName' as the applicationName in the sample, the users I created were mapped to this app name. The Sharepoint samples use an applicationName of "/", so the users won't show up unless they are the same.
TechNet SharePoint 2007 Authentication Samples This first article describes the most basic configuration required, which is essentially to set the authentication mode of your SharePoint site to 'Forms' in Central Administration -> Application Management -> Authentication providers, and set the membership and role provider names. The other articles tell you to put the configuration in the web.config files of both the Central Administration site and your SharePoint site. After all my work I removed the web.config specific configuration and only left the machine.config entries, and everything still worked. Lesson: if you use the right applicationName, you can save yourself a lot of work (you can ignore the articles below, but they provide good detail if you get stuck. Nick Swan's Blog - SharePoint 2007 Forms AuthenticationSharePoint Team Blog - Configuring Multiple Authentication ProvidersSharePoint Unplugged - Forms Based Auth in MOSS
TechNet SharePoint 2007 Authentication Samples
This first article describes the most basic configuration required, which is essentially to set the authentication mode of your SharePoint site to 'Forms' in Central Administration -> Application Management -> Authentication providers, and set the membership and role provider names. The other articles tell you to put the configuration in the web.config files of both the Central Administration site and your SharePoint site. After all my work I removed the web.config specific configuration and only left the machine.config entries, and everything still worked. Lesson: if you use the right applicationName, you can save yourself a lot of work (you can ignore the articles below, but they provide good detail if you get stuck.
Nick Swan's Blog - SharePoint 2007 Forms AuthenticationSharePoint Team Blog - Configuring Multiple Authentication ProvidersSharePoint Unplugged - Forms Based Auth in MOSS
The blogs above describe doing this in the two places mentioned, I found that only the 'Site Collection Administrator' setting is necessary. I don't know the difference between the two, but since the policy section seems more oriented toward overriding or restricting specific user permissions, I'm going to stick with the site collection administrator setting.
Error conditions:
SharePoint Designer 2007 and Forms Based Auth
A note on using a site with Forms based Auth. SharePoint Designer. There are two ways you can use this with Forms based auth. The first (and what SharePoint Designer tells you to do) is to sign into the site first and select the 'Sign me in automatically' checkbox. Alternatively, you can use the Intranet/Extranet scenario described in of the team blog above. You can have the same SharePoint site accessible using different authentication schemes by 'extending' a site. (Central Administration -> Application Management -> Create or Extend Web Application.) When you extend an existing site, you create a new Zone, and each zone can use a different authentication mechanism and membership provider. I extended my SharePoint site by specifying a new web site/port combination, and left it in Windows auth mode. I can access this site from SharePoint Designer directly. I'm not sure if this will end up creating problems such as broken links, etc., but it works.