Tuesday, December 2, 2008

Active Directory Membership Provider with Forms Authentication in MOSS 2007

ASP.NET 2.0 Provider model has introduced a set of rich features to store states using a layer of providers . So users are not needed to directly call to databases or active directory. Some of these Providers are SqlMembershipProvider, ActiveDirectoryMembershipProvider, SqlSiteMapProvider ..etc .

The ASP.NET 2.0 Provider model has built in a way that the main functionality of the system is separate from the data sources. It means we can easily change data sources without harming the logic by simply changing providers. ASP.NET Membership Provider works in a similar way where controls like logins and membership service talk to membership data sources through data providers.

MOSS 2007 can use Active Directory as the data source using the ActiveDirectoryMembershipProvider.You can establish forms authentication with AD using the following procedure

in the web.config add following LDAP connection string
   1: < connectionstrings> 
   2: < add connectionstring="LDAP://,
   3:       DC=IRONONEMS" name="ADServices"> 
   4: </connectionstrings> 

After that provide information on the membership provider

   1: < membership defaultprovider="ADProvider"> 
   2:   < providers> 
   3:     < add name="ADProvider" 
   4:       type="System.Web.Security.ActiveDirectoryMembershipProvider, 
   5:       System.Web, Version=, Culture=neutral,
   6:       PublicKeyToken=b03f5f7f11d50a3a" 
   7:       connectionstringname="ADServices" 
   8:       connectionusername="MLEARNINGTEST\Test" 
   9:       connectionpassword="****"           
  10:       attributemapusername="sAMAccountName"> 
  11:     </add> 
  12:   </providers> 
  13: </membership> 

provide above information in the web.config file of the Central Administration site as well.

Now go to Sharepoint Central Administration to include authentication provider details.

In Application Management section click on Authentication Providers and select the current web application. Click on the default provider and modify the authentication type to be Forms Authentication. Enable anonymous access and give the name of provider as ADProvider which we had entered in the web.config.

After that go to Site Collection Administrators and select the first administrators for the site from the domain specified in the ldap connection string of the ADProvider

This should switch on Forms authentication for your MOSS 2007 web application

Saturday, November 22, 2008

Recover Linux after installing Windows XP

Recently I had to repair windows xp due to some errors. But after the repair i found that i'm unable to log in to Debian because Grub boot loader is missing and instead grub windows boot loader has activated. I did some research and found out following process.

   1: sudo grub

Then grub> will appear

   1: find /boot/grub/stage1 

The reply was (hd0, 8) so i had to use them as parameters in later commands

   1: root (hd0,8) 
   2: setup (hd0) 
   3: quit 

Easy as that .. that did solve my problem

Thursday, October 23, 2008

MOSS 2007 "Cannot complete this action please try again" Error

Recently in a SharePoint site i came across this error when i was accessing the Default.aspx page. A page refresh would bring the actual page but error is so annoying. I did some research in to the matter and found out the problem resides with the Shared Service Provider(SSP) associated with my site.

I couldn't access the default SSP from the sharepoint central administration as well.the link did not work. So the trick was to create new SSP with a new sharepoint website and bring the default website(whatever you need to work properly) to the new SSP. then make that SSP the default.you can delete the old SSP as it is no longer required.

Tuesday, October 21, 2008

Move a SharePoint site from one server to another

Recently i got a task to backup a running SharePoint site from a development server and to restore in another server for deployment.SharePoint server 2007 comes with a nice web interface called sharepoint central administration.in central administration there is a section for backup and restore section in Operations -> Backup and restore -> Perform a backup . although backups work (sometimes) restore jobs failed completely.

Then i tried the stsadm command which worked for me ultimately.

Using command prompt cd to the directory “C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN” where the Sharepoint is installed

then type
   1: stsadm -o backup -url http://bakupsite/ -filename backup.bak

At the server you need to deploy the site,create new SharePoint site and then type

   1: stsadm -o restore -url http://restoresite/ -overwrite -filename backup.bak 

Wednesday, February 20, 2008

Toshiba Satellite with Ubuntu -the sound problem

Toshiba satellite A200 notebooks equipped with 82801G (ICH7 Family) High Definition Audio Controller which does not have built in ubuntu support.
you can either compile the module from the source or just do an apt-get which is much easier

just do this
apt-get install linux-backports-modules-2.6.22-14-generic

it will solve the problem.(i tested with gutsy but it may work with others also)

Tuesday, January 1, 2008

GSOC 2007

Although its very late....i thought of writing something about Google Summer of Code 2007.It was one of the best experience i had in my life.thanks to Google and my mentor organization(LSF - Sahana Project) i finally managed to complete my project which is regarding a Fund Management Module for Sahana(My Proposal)

Thanks Google...I love You !!!!!