C# - Implementing A Membership System Using OpenID?

Jan 26, 2011

I'm looking to implement a membership system using OpenID for my ASP.NET application, similar to the system used here on StackOverflow. I'm aware that the OpenAuth library is generally recognized as the way to go, but I'm having trouble figuring out how to implement it.

I use NHibernate to persist my domain objects. I have a Users table with a username column, email column, etc. I'm not sure how to integrate OpenID with my own users table, and I haven't found any good tutorials on this. Does anyone have any experience with this? What is the best way to go about doing it?

View 3 Replies


Similar Messages:

Session Management After Implementing Openid?

Aug 16, 2010

i have implemented the the openid in my page using dotnet open id when i get authenticated iam storing the details provided by openid provider in my database and creating a session of that username and redirecting the user to login protected page it is working fine but some time if i left the page idle for some time and then do any kind of postback then the session is lost and my page do not allows me to do any thing as it is login protected some time it is working fine without any problem. can you suggest me why is it so.

View 1 Replies

Implementing Google Accounts' OpenID Like Stackoverflow?

Sep 17, 2010

Firstly, This question may be asked. But I could not get the information i am looking for.

I am creating a website which should take to [URL] where the user enters his account information and it redirect back to my website similar to how stack over flow is doing when we click on gmail image.

I am trying to implement a website in .net.

list a step by step procedure to implement it or suggest some documentation to follow.

I clearly dont want other types of openID implemention where u enter the open id and pick ur open id provider.

View 2 Replies

Implementing OpenId In Custom Application Where Users Are Created By Administrator Only?

Feb 16, 2011

In my asp.net application, users are created by the administrators & those users need to log-in into the system using their own email/password or openid. So what is the best option to implement in this scenario?

I mean, as users can't register them self,do administrator required to associate each openid with the users & what kind of table structure do I need?

And do I also need the log-in interface like that of [URL] showing multiple types of authentication(default & openid from various providers)?

View 1 Replies

Use DotNet OpenID Together With Membership?

Sep 13, 2010

I would like to know if is possible to use DotNet OpenID together with ASP.NET membership. Or other way or allow OpenId account in ASP.NET membership.

View 1 Replies

Recommendation For Handling Custom User Properties With OpenID Membership

Jul 12, 2010

I'm using DotNetOpenAuth as my membership system, and the way I have it working now seems to be working quite well. What I'd like to do however is build into my website the ability to check user credentials against the AuthCookie rather than a session. In the membership provider, I can check for the username like this

string UserName = System.Web.HttpContext.Current.User.Identity.Name;
''# which returns the OpenId ClaimedIdentifier

What I'm wondering is if there is a way to extend this so that I can retrieve custom properties from the AuthCookie rather than having to create my own session object. Currently I have this setup.

UserSessionModal
Namespace Domain
Public Class UserSessionModel
Public Property ID As Integer
Public Property RegionID As Integer
Public Property Username As String
Public Property Slug As String
Public Sub New(ByVal user As User)
_ID = user.ID
_RegionID = user.RegionID
_Username = user.UserName
_Slug = Replace(user.UserName, " ", "-")
End Sub
End Class
End Namespace

BaseController (inherited by all controllers)
Protected Overrides Function CreateActionInvoker() As System.Web.Mvc.IActionInvoker
''# Create a UserInfo object for the logged in user
''# and store it in a session state.
If Session("UserInfo") Is Nothing AndAlso User.Identity.IsAuthenticated Then
Dim user As Domain.UserSessionModel = New Domain.UserSessionModel(OpenIdService.GetOpenId(HttpContext.User.Identity.Name).User)
Session("UserInfo") = user
End If
Return MyBase.CreateActionInvoker()
End Function

Then in my views I do something like this

<%
Dim user As MyApp.Core.Domain.UserSessionModel = DirectCast(Session("UserInfo"), MyApp.Core.Domain.UserSessionModel)
%>
<%: Html.ActionLink(user.UserName, "Details", "Users", New With {.id = user.ID, .slug = user.Slug}, Nothing)%>

What I really need to be able to do is remove the Session stuff all together and just simply check the AuthCookie for my custom properties ID, RegionID, Username, and Slug. I can already get the "ClaimedIdentifier" out of the AuthCookie using HttpContext.User.Identity.Name... I just need to be able to extend it.

View 1 Replies

C# - MVC Membership : Implementing Email Address Validation After User Registration

Jun 29, 2010

I'm building an ASP.NET MVC 2 site, where I want to have users verify their email address after they register.

I want to send an email to the address with a link that the user can click to verify their email, and then handle the clicking of that link (the link will contain a specific id, of course).

Of course, this is easy to manually implement, but is there anything already built in to ASP.NET that has such a function?

View 2 Replies

Web Forms :: Implementing Logic For Bus Reservation System

Aug 24, 2013

In bus reservation mutiple end-user are requested for single seat at a time. How we can handle the multiple user request. how we can reserved the seat for one requester and how to handle the other requests for that seat.

View 1 Replies

Uploading Membership System To Web?

Nov 8, 2010

I am having problems with the asp membership system when uploading it to the web.

I uploaded the database to the web, which works fine, but when i try to login in using the log in control on one page, i get the error:

A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: TCP Provider, error: 0 - No such host is known.)
what would cause this? what have i done wrong?

View 2 Replies

Implementing Item To Item Recommended System

Nov 12, 2010

I am developing an application of library management system in asp.net. I want to implement item recomender system. when user search any bsook like c# ,the system also show related other books of c# in the botom of page.

View 1 Replies

Security :: Linking Asp Membership To An External System?

Oct 7, 2010

I've had a look through the forums but I couln't find a concrete answer - I found some things that point me in the right direction but I would like to just ask for some clarification.My requirements are as follows:I have an external system, with an API that allows me to log in a user, and returns whether or not it was successful. This can only be done through the API, it can not be done with a direct DB connection.I want to create a site that can only be accessed by someone who has a login to this external system. Through the site they will only be able to log-in, there will be no possibility to change password etc, this is all done in the external system by an admin.I like the ASP membership system, and the way it works with anonymous and member views and would like to continue to use it. My question is, how do I do this? Do I create a custom membership provider that overrides all the methods of the usual membership provider? And how will the fact that all I actually want to do is allow the user to login affect things? There will be no ability to change details etc.

View 6 Replies

Security :: Use A Third Party (CAS) Authentication System While Still Using Membership?

Apr 21, 2010

I need to convert a web site using traditional ASP.Net login,membership/role with SQL to a custom system. I need to use a third party (CAS) authentication system while still using membership and roles to control access to content and User.Identity functions.What would be the best way to accomplish this? I use the <deny> and <allow> user throughout the site to control page access.

View 3 Replies

Security :: Creating A New User With The Built-in Membership System?

Jan 13, 2010

is there a way to snag the database id of a newly created user after CreateUser has been called? I need to be able to tie that id to another database table. From what my book shows me, it looks like member info is encrypted, so merely looking at the membership database table.

View 11 Replies

Security :: Create Membership System - No Suitable Method Found To Override

Jul 19, 2010

I am trying to create my own membership system. Therefore I created my own membershipuser class and membership provider class. But I am getting the following error on Createuser method of My membership provider class; no suitable method found to override

This is how my CreateUser method looks like:

public override MyMembershipUser CreateUser(string username, string password, string email, string status, int registerd_on, out UserCreationStatus creation_status)

[code...]

View 6 Replies

Security :: Membership And Profile System : Getting Information Of The Authenticated User From Database?

Aug 18, 2010

I m trying to use the profile system to get information of the authenticated user form the data base, just like the session system : the user is authenticated then I set same variable with information of this user coming from data base !I am familiar with PHP so i m trying to do it like that !Also, i woul like to join my own data base and the asp.net membership database !

View 1 Replies

Intermittent Membership.GetUser() Error - Unable To Cast Object Of Type System.Guid?

Jan 24, 2011

This error is occuring randomly, and I can't seem to pinpoint what is causing it. For the most part, the code works fine. I'm confused why it works sometimes, but then suddently craps out on me, lol.It happens in the code when I call upon the asp.net membership provider. It only seems to happen when i use Membership.GetUser() to grab the logged in user's information.

View 9 Replies

C# - How To Use OpenID

Jan 11, 2010

I would like to create a site that authenticates using Google's OpenID. How would I do this? Also, how would I use roles with custom tables?

View 3 Replies

Unable To Connect To OpenId Provider

Feb 7, 2011

When I run in visual studio I am able to connect to openid provider, But if I host app in IIS ,I am not able to connect to openid provider. (I am getting error at CreateRequest)

what settings has to be done in IIS so that I can connect to the Openid Provider. Below is the error I am getting

[InvalidOperationException: Sequence
contains no elements]
System.Linq.Enumerable.First(IEnumerable`1
source) +336
DotNetOpenAuth.OpenId.RelyingParty.OpenIdRelyingParty.CreateRequest(Identifier
userSuppliedIdentifier)
[ProtocolException: No OpenID endpoint
found.]
DotNetOpenAuth.OpenId.RelyingParty.OpenIdRelyingParty.CreateRequest(Identifier
userSuppliedIdentifier)

View 1 Replies

C# - Get User Details From OpenID Server?

May 31, 2010

I'm wanting to save some OpenId fields to a localdatabase table, such as

-Full Name
-openid url
-passworg

how to get those attributes from openid server? send me some example code in asp.net, c#...

View 1 Replies

Sample Code For Own OpenId Server?

Apr 6, 2010

There are sample codes on the net for OpenId Client but none for OpenId Server. Do you know some? I know about dotnetopenAuth but there seem to be no tut on how to use as OpenId Provider. I don't even know if it can do that. Maybe it can just be used to create openid consumer app.

View 1 Replies

Security :: Add OpenID Check Authentication?

Mar 12, 2010

I need to know how we can add OpenID Authentication in asp.net. For example, in some web site we can login using gmail account or wordpress account or twitter account some other public sites. I want know how we can add that in our site too. Let me know the code for that or can you give me more details where I can get that information or sample code.

View 1 Replies

DotNetOpenAuth And Google OpenId Parameters

Mar 16, 2011

I am still reading on using dotnetopenauth and google openid. In the google docs they mention some parameters that need to be passed like:

"openid.ns", "openid.claimed_id", "openid.identity", "openid.ax.type.email" etc ...

Does DotNetOpenAuth send all those params on its own seamlessly?

View 1 Replies

C# - Authenticate Using OpenID Without Login Through Provider?

Dec 23, 2010

create web application to connect to MySpace Offsite App and I want to authenticate I used the following code

var openid = new OpenIdRelyingParty();
IAuthenticationRequest request = openid.CreateRequest("http://www.myspace.com/thabet084");

[code]...

View 2 Replies

Retrieve Email Id Information From Openid Response?

Jul 17, 2010

I am storing response from opeid provider using

NameValueCollection query = HttpContext.Current.Request.QueryString;

I am sending request for emailid as

"&openid.ax.type.email=" +
HttpUtility.UrlEncode("http://schema.openid.net/contact/email"))

but receiving emailid in openid.ext1.value.email in some case and openid.ax.value.email in others.

View 2 Replies

C# - Using Microsoft Live As An OpenID Option To Application

Mar 31, 2011

Coding Platform: ASP.NET 4.0 with C#

Building a website using ASP.NET membership(forms authentication) and options to link Open IDs to it. I would like to have Microsoft Live as an OpenID option in this website. Well I have not seen Login using Windows Live ID except at forums.asp.net, but then both are Microsoft websites.

Today, I stumbled upon a website that seems to be using Microsoft Live Connect or whatever. I tried searching for it but I couldn't get any documentation regarding an API for Live Connect.

Here's the URL: http://messengerconnectidentity.mslivelabs.com/

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved