If you are following the posts for the sample Cognos SDK solution then you won’t want to miss the last few posts that talk about the CognosSDK.cs class file. Follow the link below to take you to the Cognos SDK discussion about authenticating a user session.
http://cognos8helpsdkguide.blogspot.com/2007/12/cognossdkcs-authentication.html