Archive

Archive for February, 2008

Toronto CodeCamp is only ONE day away!

February 29th, 2008 No comments

In just less than 32 hours , the Toronto CodeCamp 2008 will be held. Over 700 people have registered so far and registration is still open. If you haven’t registered yet ,you’d better hurry! This is an amazing opportunity for learning and networking with peers and industry leaders. Unfortunately, Eli Robillard (Toronto’s Uber SharePoint MVP) has taken a break as he has been so busy these days, but no worries – both myself and Bill Brockbank will be representing the SharePoint community along with bunch of other *great* speakers. I’ll be presenting one session:

Delving into custom authentication providers in SharePoint (02:30 PM – 03:45 PM Room: E.S. Jackson)

For those of you who attended this session in SharePoint user group , because I love you so much and I’d like to see you over and over again , I am coming with a fairly new presentation. I have managed to change the background of my PowerPoint deck, added couple new pictures (Just kidding) LOL …… In all seriousness , I have added the following topics to the previous presentation and got rid of bunch of slides.

  1. Utilities that must be shipped with any FBA implementations (These are NOT the tools we already talked about)
  2. Anonymous Access Challenges
  3. Single Sign ON with other ASP.NET apps
  4. MySites (If time)
  5. A new State Provider that I have just finished developing it (If time)

I’m telling you now that it is going to be a fast-paced session , because my mantra is : To “Share” as many “Points” as possible I also don’t like unreal demos (a.k.a Hello World! – Copied and pasted from someone else’s demo) .You don’t need to listen to my funny accent for those stuff, right?;)As always, I will be showcasing one of my previous projects.

See you on Saturday, March 1.

Categories: General, MOSS 2007, UG/CodeCamp Tags:

Central Admin Can’t See My Authentication Provider!

February 22nd, 2008 4 comments

Received today from CodePlex:

“Hi Reza, I have created a custom membership provider for my MOSS site [ it checks creds against a propriteray store]. I have implemented these methods in the CustomProviderClass public class MyCustomProvider:MembershipProvider
* GetAllUsers
* ValidateUser
* GetUser
* FindUsersByName
I followed the technet links to register the custom provider in the sharepoint Admin site as well as my custom website on which I would like to have FBA. Unfortunately I am struggling at the point where I am not able to add users….. Central Administration > Application Management > Policy for Web Application > Add Users the user is not found when I check names, yes I use MyProvider:username BTW I tested my custom provider in ASP.NET 2.0 and it works super Please advice, thanks a lot”

First of all , you don’t need to specify MyProvider:username for the user to be resolved. In a healthy FBA configuration putting username alone should be okay. However , when you hover over the username , it must show MyProvider:username as the tooltip. This is one of the ways that you can make sure your user belongs to your custom authentication provider , not a similar name in AD or any other authentication providers.

Secondly, the fact that your custom authentication provider works in your ASP.NET application or even in your SharePoint web application (whatever zone you specify for your FBA stuff ) doesn’t guarantee that it should work in Central administration or SSP. They are different web applications running under different application pools (they better be ;)) with different web.config files. Here are two things that I’d check:

1) FBA settings ( Are they the same in SharePoint Web Application and Central admin) – You don’t need to include role provider settings in central admin.

2) Debug your authentication provider to see if it gets initialized. Then step through your various methods and see if there is an exception thrown somewhere in GetUser method that is not propagated up in the call stack or you have handled it without logging it (bad bad idea). Make sure you do an IISRESET and browse to your site once before you attach to the worker process, because your auth provider might have been already initialized and you don’t see the initialized method get hit again – GetUser gets hit everytime a name is resolved. This is where a good instrumented code comes to light to nail down the issue. Please Please make sure that you write plenty of tracing code in every piece of functionality you develop. I guarantee that you won’t regret it. Debugging can be done in two ways. One way is what I described above or you can place a trace on the SQL server side to see if the communication with back-end database ever happens and what gets transmitted. Many people would prefer the latter one.

Hope this helps,

Categories: MOSS 2007 Tags:

The Importance of Network Load Balancing (Part 1): Introduction

February 21st, 2008 1 comment

Hello guys! I’m back to my little cyber space and ready to write about SharePoint stuff again – This time about one of my favorite topics , load balancing. What else can I write about? Seriously! How to improve your relationship with your wife!? 😉 This time I ‘d like to talk about the importance of network load balancing in your development cycle and how it can cause some confusions and potentially unexpected results when you deploy your work to a farm installation. All of us have had prior experiences in which everything works perfectly on our machine, but the minute we deploy our stuff to a customer’s site and we go live , things gets messy. Quite frankly, the mentality that your code is not gonna live on a single machine forever really helps you to look at the bigger picture while you are developing or you’re drawing at the architect’s table. For example……Hey dude! your code is going to be executed in a multi-threaded environment so you got to be careful when caching objects  or , God forbid , caching objects that are not thread safe. Here is another one: Man! iterating through all these list items are not really a good idea, why don’t find a faster approach to retrieve what you want? .Yeah , you keep hearing these advices , some people listen up, improve their coding techniques and some others don’t give a damn. You?…….. okay, okay , I heard ya loooud and clear.I’m happy to hear that you belong to the first group, so let’s relax and slouch down while I’m cooking another SharePoint recipe for you (titled “The Importance of Network Load Balancing”) in my new blog posts series.

Here are the action items that I have in mind at the moment and planning to write about in the upcoming posts:

Part 1) Introduction: This is what you’re right in it!! I don’t really know what to say here. Sounds like Metadata about metadata.

Part 2) Setup: How to setup a load-balanced environment for our testing purposes using Microsoft’s Network Load Balancing technology that is included with Windows 2003 Server operating system. I know NLB doesn’t scale and is not what many organizations utilize to distribute client demands between multiple servers , but that’s not important for our testing purposes (You can always use your intelligence to overcome shortcomings, right?) . No matter what you use for load balancing , these posts would be an interesting tidbit of information that maybe valuable to you.

Part 3) Features , Event handlers and Timer jobs: This is pretty much self-explanatory. In this post ,I would like to talk about the things that you should consider while developing features, event handlers and timers jobs deployed to web farms.

Part 4) Participating in a shared forms authentication : Thankfully, You can have forms authentication in a distributed environment in a farm (or even across multiple applications on a single WFE server). When forms authentication is enabled across multiple applications, users are not challenged to enter their credentials again when switching between those apps. In this post, I will show you how forms based authentication cookie can be shared across multiple web applications even in a load-balanced environment. Yes, you may not need an SSO solution at all and you don’t even know it!

Honestly , it is quite scary when you (as a blogger) announce something like this to your readers whilst you haven’t even written one word of your posts – It is just bunch of thoughts in your mind and experiences . Well, I might come back to this page and move things around a bit, but writing an agenda like this really helps me in two ways:

1) To create a path to follow.

2) To be obliged to come back and get the job done. For me this is even more important than the first one, because a lot of times I have an idea and I think wow! this can turn out to be a great blog post , but I slack and that post never get written. I know I know I’m lazy 🙂

Categories: MOSS 2007 Tags:

Anonymous Users In SharePoint (Part 3) : Welcome Guest

February 10th, 2008 20 comments
WordPress › Error

There has been a critical error on this website.

Learn more about troubleshooting WordPress.