C# - MVC Single Sign-on And Roles?

Aug 30, 2010

I have basic Single Sign-On working across 2 MVC sites (call them SiteA and SiteB) using something along the lines of the following method:http://forums.asp.net/p/1023838/2614630.aspxThey are on sub-domains of the same domain and share hashencryption keys etc in web.config. I've modified the cookie so it is accessible to all Sites on the same domain. All of this seems to be working ok.The sites are on separate servers without access to the same SQL database, so only SiteA actually holds the user login details. SiteB has a membership database, but with empty users.This works fine for my required scenario which is:1) User logs into SiteA2) The application loads data from SiteA (by AJAX) and SiteB (by AJAX using JSONP)I have the following LogOn Action on my AccountController for SiteA, which is where the "magic" happens:

[HttpPost]
public ActionResult LogOn(LogOnModel model, string returnUrl)
{

[code]...

View 2 Replies


Similar Messages:

VS 2008 Single Sign On And Sharepoint

Jan 15, 2010

we have developed a ASP.NET application that required a username and password to login and use the application.Now on of our customers wants to use Single Sign on with their Microsoft Sharepoint Portal.

Basically they want their users to be able to login to the portal, and then be able to access our application, without having to provide their login details again.Does anyone have experience with implementing Single Sign on?

View 4 Replies

Security :: Single Sign On Different Domains?

Oct 13, 2010

I have a web app located at [URL] and I have several domains, such as [URL], [URL], etc. all pointing to the same directory in IIS. I use Host Headers to acheive this by setting the 'Host Header Values' under properties for the main site (under the Web site identification section). Based on the host header value I perform different functions in my pages.

Because of the way I have it set up, all the domains share the same files, web.config, etc. I have set the 'machinekey' in my web.config and have forms authemtication. However, when I go to MyMainSite.com and log in and then the user clicks a link and gets directed to MyFirstSite.com the user is shown as logged out. I need the user to be logged in and I need to be able to access the logged in user profile to display certain information. I thought by setting the 'machinekey', i could acheive this, but it does not seem to work.

how to go about having a single log on for my users?

The articles I have found show the same domain or have different domains each with a different web.config. The way they describe does not seem to work for me.

View 1 Replies

Security :: SSO / How To Implement Single Sign

May 4, 2010

How to implement Single sign on in asp.net web application.

Give me to full tutorial. How to implement this in two apps.

View 3 Replies

Single Sign On Across Many Domain Without Cookies?

Feb 16, 2011

m using visual studio 2008.my requirement is to implement single sign on across many domains without using cookies. is this possible?for example, i have 3 domains (hosted in 3 different systems).[URL]i implemented single sign on with cookies, if the sites are hosted in single system then it is working. but it doesnt work if cookies are disabled.i tried all made all possible google searches, but couldnt find anything useful.

View 2 Replies

Securing Single Sign-on To Web Application?

Sep 10, 2010

I need to create a single sign-on structure and my question is: is SSL a must?

Details:
The application will have a link to my web application. When the user clicks that link, their local username will be passed to my web app at which point a look-up in a mapping file is done. If that local username exists in the map, then the user is logged in. If not, then the user will be prompted to enter their network username and password, and when authenticated, an entry in the map will be created.

How do I ensure that user is who they say they are and not Joe Blow from off the street sending in an HTTP POST request with that username?

Do I have to use SSL (and if so, what does that entail)? Would adding a salt and encrypting the username be sufficient? Maybe locking it down so the source IP has to be within a controlled range?

My web app runs on IIS 6/7 and uses the ASP.NET MVC framework, if that is important.

View 3 Replies

Security :: KickApps With VS Single Sign On?

Feb 15, 2011

I am trying to get this to work, and having a heck of a time.

I want users who log into my site to be able to access the KickApps site I created using single sign on.

They provided a helper code:

http://www.kickdeveloper.com/images/stories/docs/KickApps.cs

And the sample code is at the top of that.

It will not give me a response back other than "Nothing"

I am new to web services and single sign-on, and any help would be greatly appreciated. I am using the standard log-in system for vs, and want it so that after they log in, and load my special page, it redirects them to the kickapps app, where they are already signed in.

View 1 Replies

Php - Implement Single Sign On With SubDomains?

Feb 4, 2010

I would like to know how to implement Single Sign On across subdomains running on a mixture of programming platforms, asp.net and php?

View 1 Replies

VS 2010 Web Service - Single Sign On (SSO)

Jun 20, 2011

I've only worked with web services a little bit. I am working on a project now using another developer's code as a template. It is code for a single sign on (SSO).

Here is a code excerpt:

Code:
namespace xxxxxxxSSO {
/// <summary>
/// Summary description for xxxx
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]

[Code] ....

Also let me say, I have been coding in VB6/VB.NET for the past six years and am learning C# (that is what the other developer's code is written in).

setAppCredentials() is the beginning of a lot of sub-calls and I have gotten that all to work when I was running the service from within its own Visual Studio project.

Where I am having the problem is setting credentialHeader.Username and credentialHeader.Password. credentialHeader is nothing when I call validateCredentials().

I didn't see how I had these exposed to me in order to set them. So the developer said Create a client that consumes that service and set the values there and call your method.. But I still don't see how it's exposed to my consumer. I have this line of code in the consumer

Code : Dim myWebService As New localhost.xxxMemberService

(Back to VB!,) but I still don't see credentialHeader exposed.

The only other thing I see in the webservice code that might be relevant is this:

Code:
/// <remarks/>
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Xml", "4.0.30319.1")]
[System.SerializableAttribute()]
[System.Diagnostics.DebuggerStepThroughAttribute()]
[System.ComponentModel.DesignerCategoryAttribute("code")]

[Code] ....

which is in a file called referenes.cs.

View 5 Replies

Security :: Single Sign-On SSO With Forms Authentication?

May 20, 2010

I have this tutorial on Single Sign On with forms authentication.The following link:

[URL]

I did item number 1 which is "SSO for parent and child application in the virtual sub-directory" and it works fine BUT I can't seem to stay logged in because each time I leave and reenter the application I get redirected to the login page.

Is this an inherent feature of forms authentication?

What happened to authorized cookie generated by forms authentication?

While waiting for responses, I will look for answers.

View 5 Replies

Architecture :: Single Sign On Web And Windows Apps?

Sep 18, 2010

We, at our company, are developing a file sharing application which will allow users to upload/download files. This application will be part of the suite of other applications. We will be adding a desktop client (windows app) which is an upload/download manager which will assist users to queue in multiple large files for upload/download. There are a couple of questions related to design for these applications:

1. We would like to implement Single Sign-On for all these applications (including desktop client). We would like users to login to web and once they do that, they can browse through applications without logging in again. We will be implementing a authetication service using WCF. The requirement is that we do not want to add authentication functionality to desktop client. So users will need to login to our web application. We can write cookie to user's machines and will work for web applications. Can the desktop client use the same cookie to autheticate itself? Or there are other ways we can achieve it? 2. We also do not want that when desktop client is uploading/downloading multiple files that its session is expired and the user need to re-authenticate through web. How can we achieve it? How does other Upload/Download Managers (like MS File Trasnfer Manager) work?

View 9 Replies

Security :: Implement Single Sign-On Using Membership API?

Apr 7, 2010

I am working as a trainee in a software company.

I want to implement Single Sign-On in two different applications(different domains).

View 2 Replies

C# - .NET Cross-Sub-Domain Single Sign-On Cookies

Oct 28, 2010

I have a Single Sign-on solution which is working great in our test environment. It uses Cross-Sub-Domain cookies to share the authentication ticket between 2 web applications. Sign-on is done only on one of the applications and on the second site the user is authenticated by the cookie created by the first site.The problem is that when I roll it into the production environment the single sign-on no longer works. I'm looking for any ideas on why this might be. More details below:1) Both apps are implemented using ASP.NET MVC2

[code]...

View 1 Replies

Security :: Configure for Single Sign On Authentication?

Feb 17, 2010

We have intranet based web application in ASP.Net, needs to be configure for single sign on authentication at client place.

Our client has existing intranet based web site in classic ASP. After successful login to this site in asp, employee will have a link to access our web portal without entering any credentials again. Please note that both sites are having differnet virtual
directories or different domains.

Is there any way to achieve this sinlge sign on authentication than LDAP or Cokie based authentication.

Does Microsoft 3.5 provides some enterprise service to acheive the same?

View 5 Replies

C# - Use A Guid For Implementing Single Sign On The Same Domain?

Aug 23, 2010

How can I use a Guid for implementing single sign on the same domain? I can't use sessions as the different web apps would open in new windows hence loosing the session.

Technology used: ASP.net 3.5, MVC2 architecture, C#.

View 1 Replies

.net - Make Single Sign On Work With Framework 4.0?

Sep 20, 2010

I have a parent web application and a child web application. I am using single sign on between them. The child application is supposed to redirect anonymous users to the login page of the parent application We just updated both to .net 4.0 framework and now the SSO doesn't work anymore.The setup is as follows. I have the machineKey tag all set up with validation key and decryption key in both applications.then, for authentication tag i have the following in the child app (I have replaced the actual parent app's url with "parentApp" for privacy):

<authentication mode="Forms">
<forms name=".SSOAuth" loginUrl="parentApp/Login.aspx" path="/" protection="All"/>
</authentication>

[code]...

View 1 Replies

Security :: Use The Concept Of Single Sign On (SSO) In Asp Application?

Sep 30, 2010

I am trying to use the concept of Single Sign On (SSO) in my asp.net application.

for the purpose i have created a main domain say
mydomain.com.

now i have 2 subdomains
sub1.mydomain.com & sub2.mydomain.com.

I am running these very fine. But now I want to have a SSO for my domains. For the same have

googled lot and found some stuff such as adding machine key to web.config and specifying domain names in cookies.

But it is not at all working for me. when I specify the domain name for cookies i am unable to sign out.

I am using FormsAuthentication in asp.net.

Following is the code I have in my web.config.

[Code]....

I have the same code in web.config of each domain.
I have placed the code for each domain in different directory on my website.
for ex. mydomain.com ---------> F:/HostedSites/mydomain
sub1.mydomain.com ---------> F:/HostedSites/subdomain1
sub2.mydomain.com ---------> F:/HostedSites/subdomain2

my Authentication code is

[Code]....
and sign out code is

[Code]....

Can anybody tell me where exactly I am wrong ? what changes do i need to do at server end also.

I am checking this on my testing domain ie. mydomain.tv. can this be a problem ?

View 2 Replies

Security :: ReturnUrl And Subdomain For Single Sign-on?

Feb 11, 2011

[Code]....

MyDomain.com. But ReturnUrl has value

[Code]....

View 1 Replies

Security :: Single Sign On With Multiple Subdomains?

Apr 21, 2010

I have 2 subdomains:

www.mysite.com
store.mysite.com

I followed these instructions: http://www.codeproject.com/KB/web-security/aspnetsinglesignon.aspx

The only thing I don't understand is where to put the cookie code?

[Code]....

Does this go in the LoginControl_LoggedIn event? Application_AuthenticateRequest?

Also, what if I have 2 different domains?

View 2 Replies

Single Sign On Error - Could Not Find Email

May 13, 2014

I have a SSO application that runs on IIS which works fine on my own office and several other customers but this one specific customer keep getting this error in image below. I know the following settings are required for this specific SSO to work: Windows Authentication with no Anonymous access, set browser security settings to login with logged in user's credentials. The exception says "Could not find email for [BjoJon001]/[Domain nameBjoJon001]". Shouldn't it be just [Domain nameBjoJon001]? Could something in their specific Active Directory be weird? I'm guessing this line is throwing the exception

Code:
If UserFound.GetDirectoryEntry().Properties.Item("mail").Value.ToString.Trim = "" Then
Throw New Exception("Hittade ingen E-postadress for anvndare")
End If

[code]....

View 1 Replies

Social Networking :: Single Sign On Using Facebook

Nov 23, 2013

Based on post (Single Sign on using Facebook), In my asp.net application I added the single sign on functionalty using FaceBook. But it only shows the userid, email profile photo , id etc. My need is, after getting the credentials the suser should also be logged in to my application.For that i need the password also.

 If the user is new to my application, i should register the user to my application as well.I am inluding the login button click event handler which In which I added code for my registration/sign in 

#region Login-Facebook protected void Login(object sender, EventArgs e) {
FaceBookConnect.Authorize("user_photos,email", Request.Url.AbsoluteUri.Split('?')[0]);
Access _access = new Access(); List<CheckEmail_Result> list = _access.CheckDuplicate(lblEmail.Text);
if (list.Count() > 0) {

[Code] .....

View 1 Replies

Security :: Single Sign On IIS 7 Multiple Application Pool

Oct 20, 2010

We migrated our web server to window server 2008, IIS 7.

We have single sign on application - that we login through one application called "users" and then no need to login to other applications, they all use the same machine key and cookie.

it works fine when all then applications under the same application pool.

but we have one application that is asp.net 2005. (the rest are asp.net 2003) the user application is in asp.net 2003 and that other application is in asp.net 2005.

so each application is in a different application pool. -

one pool to asp.net 1.1 and other pool to asp.net 2.

when I run the asp.net 2005 application

I get the login page and after I login I get the following errer:

HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.

Requested Url: /users/Unauthorised.aspx

Important: If I switch the "user" application (the login) to work under the same pool as my asp.net 2005 application, then it works fine with the asp.net 2005 application,but I get the above error for the asp.net 2003 applications

All this happened after we switched to IIS 7 Windows 2008, with IIS 6 it works great!

View 2 Replies

WCF Service - .net Hosting - Single Sign On, How To Pass Credentials

Jan 7, 2010

My scenario is this - I have two ASP.net websites. Both sites run on the same machine and I have implemented single sign on relatively simply using the default asp.net membership provider (Forms based authentication).I have a new WCF service on one site, which will be called from the other site. A user will be logged into the site, but the call to the service will be made from the codebehind following a postback.Can somebody point me in the right direction so that I can pass through the Forms based credentials of the logged in user to the WCF service on the other site? Presently it's passing the NETWORKSERVICE windows credentials.

View 2 Replies

Security :: Refreshing Single Sign-on Forms Authentication?

Jun 10, 2010

I've had no problems implementing CAS however I have hit an issue with its timeout. It appears my Uni has the timeout set to about 15 minutes. Some forms (specifically ones for our HR department) take a lot longer than 15 minutes to fill out. The result being that when they click the Save/Submit/whatever button, CAS refreshes its login, sends them back to the same page, and resets the page to default (since it's essentially reaccessing it).

Is there any easy way to force my SSO to refresh at set intervals? I tried to use another page (embedded in an iframe that I added to all .Master pages) whose page load contained:


[Code]....

View 1 Replies

Security :: Implement Cookieless Single Sign-on Across Many Domains?

Feb 16, 2011

im using visual studio 2008. my requirement is to implement single sign on across many domains without using cookies. is this possible? for example, i have 3 domains (hosted in 3 different systems). www.domain1.com www.domain2.com www.domain3.com and cookies are disabled. i implemented single sign on with cookies, if the sites are hosted in single system then it is working. but it doesnt work if cookies are disabled. i tried all made all possible google searches, but couldnt find anything useful.

View 5 Replies







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