Posts

DISABLE FIPS ALGORITHMS BEFORE INSTALLING SHAREPOINT 2010

SharePoint 2010 does not support FIPS compliant algorithms.  Because of this, you will need to change the Local Security Policy; as well as change some registry settings.

Local Security Policy changes…

Go to Start > Control Panel > Administrative tools > Local Security Policy

Under the “Local Policies” heading, select “Security Options” and look for the entry, “System cryptography: Use FIPS compliant algorithms for encryption, hashing, and signing.”

If entry this is enabled, disable it.

Registry changes…

Change all of the following values to “0”

HKLMSYSTEMControlSet001ControlLSAFipsAlgorithm

HKLMSYSTEMControlSet002ControlLSAFipsAlgorithm

HKLMSYSTEMCurrentControlSetControlLSAFipsAlgorithm

After making these changes, you should be able to install and configure SharePoint 2010 successfully.

DISPOSING OF OBJECTS IN SHAREPOINT CODE

As a SharePoint developer, I have learned many things the hard way.  One of the most important things that I learned early on was to dispose of your SPSite and SPWeb objects.  They do not dispose cleanly on their own.  If you have custom code that is being called hundreds or thousands of times a day, then your application will more than likely crash IIS.

There are 2 main ways that I have seen developers dispose of these objects.  The first is to call the Dispose() method on each object.  The second, I think, is the best method, and that is to use the Using statement.  It makes it impossible to forget to dispose of the objects.  Here’s how to use it…

using (SPSite site = new SPSite("http://www.myserver.com")) {
     using (SPWeb web = SPSite.OpenWeb()) {
          //Your code here!
     }
}

If you put all of your code where the “//Your code here!” statement is then you will never have to worry about disposing of the objects.  Even if the code throws an exception, the objects will be disposed of.  However, you should still put try-catch statements around your code to catch any errors that may occur.

If you need help checking your code for non-disposed objects, then check the SPDisposeCheck tool out.

SHAREPOINT 2010 MANAGEMENT SHELL – REGEX BASED SITE DELETION

The eGroup application services and development is currently working on a complex SharePoint 2010 deployment that involves Nintex workflow creation of sites using site templates and web services. While preparing for a demonstration we decided to remove all test sites that had been created up until that point and there were more than 50!.I’m certain you can all imagine the realization of how long this would take when faced with 5 minutes before demo time! Entering each site, visiting site settings, choosing to delete the site, confirming, rinse and repeat would have take 30+ minutes. A quick script solved the problem for us – read more to see this simple and effective script.

Read more

VMWare ThinApp APPLICATION REPOSITORY IN SharePoint 2010?

Something a co-worker asked me made me think about a way to store, backup and deliver ThinApp applications over the web from anywhere with as little jumping through hoops as possible.  While this is by no means a go-to market solution (VMWare View using PCOIP would be much better suited for that) or even a complete thought I was thinking what if we uploaded ThinApp applications to a SharePoint 2010 document library?  How would they be accessed?  Could we use it as the file share for our View/XenApp repository?  What benefits would it provide?

So I gave it a shot.  The answer is still being tested but the initial results seem promising.  By using the UNC path ability of a SharePoint doc library you can point View/XenApp to this repository by utilizing sharepointaddress.domainname.comsitedoclibraryaddress”, you can also do this from anywhere on your network (as UNC implies) and over the internet if your SharePoint 2010 solution is internet facing to access the ThinApp applications from anywhere (given the right credentials of course).

But this also had some decent side effects, you could use the power of the SharePoint document library to add descriptive data to each ThinApp application.  Such as last modified date, who packaged it, who owns it, license information, notes on the packaege, supported operating systems, etc…  Users could download the packages themselves from the library (again, credentials) and run them locally if desired.  You could configure alerts, workflows, all that fancy management stuff that makes SharePoint a great business tool to help IT manage the packaged applications.

Then there is the backups, a few lines in a scheduled PowerShell script and you have complete backups of your entire SharePoint farm including content in doc libraries.  Making backup management and restoring simple and more reliable.

Leave your thoughts below if you can come up with any more uses… more to come.

SHAREPOINT 2010: UNABLE TO BROWSE SHAREPOINT SITE FROM SHAREPOINT SERVER (WFE)

Ran into this recently where I could browse the SharePoint 2010 site from any machine or server in the environment from the internal and external networks but could not browse to it from the SharePoint server itself.  This issue typically occurs in one server deployments and is easy to resolve.

Enter the old DisableLoopBackCheck registry change.   Just regedit to

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlLsa
 
and add a DWORD value set to 1 for a entry called DisableLoopbackCheck.  Reboot and all should be good.