473,805 Members | 2,003 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

User Authentication between two websites

Hi,

Is there any possibility to authenticate an user between two websites?
I have a website through which users login and get authenticated. In
the same website I link to a different website and would like to pass
userid to the second website. My question is I want to restrict users
from going to the second website directly without getting authenticated

from the first one. Is this possible?
I know we can do this using Forms Authentication if this is in one
website.
I used below code in the web.config file of second website.
<authenticati on mode="Forms">
<forms name="Upgrade"
loginUrl="http://www.firstwebsit e.com/TestDirectory/Login.aspx"
protection="All " path="/">
</forms>
</authentication>
When I go to the second one directly, I get an error as below
*************** ***************
The resource cannot be found.
Description: 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: /TestDirectlry/Login.aspx
*************** ***************
Which appears the website is looking for /TestDirectory/Login.aspx in
the second web project.
Any help is appreciated.
Thanks.

Oct 5 '06 #1
1 1629
Potentially. It really depends on whether they are under the same domain
root. If so, you can easily set the same machine keys (which encrypt the
server token) and pull from the different sites. Session variables will not
transfer, but you can use the same token. NOTE, however, that you have to
maintain session state for both sites in the same pool to do this.

There are ways you can do this with disparate sites, but it is a royal pain
in the butt, due to security concerns.

--
Gregory A. Beamer
MVP; MCP: +I, SE, SD, DBA
http://gregorybeamer.spaces.live.com

*************** *************** *************** ****
Think outside of the box!
*************** *************** *************** ****
"shil" <jo******@gmail .comwrote in message
news:11******** **************@ i42g2000cwa.goo glegroups.com.. .
Hi,

Is there any possibility to authenticate an user between two websites?
I have a website through which users login and get authenticated. In
the same website I link to a different website and would like to pass
userid to the second website. My question is I want to restrict users
from going to the second website directly without getting authenticated

from the first one. Is this possible?
I know we can do this using Forms Authentication if this is in one
website.
I used below code in the web.config file of second website.
<authenticati on mode="Forms">
<forms name="Upgrade"
loginUrl="http://www.firstwebsit e.com/TestDirectory/Login.aspx"
protection="All " path="/">
</forms>
</authentication>
When I go to the second one directly, I get an error as below
*************** ***************
The resource cannot be found.
Description: 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: /TestDirectlry/Login.aspx
*************** ***************
Which appears the website is looking for /TestDirectory/Login.aspx in
the second web project.
Any help is appreciated.
Thanks.

Oct 5 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1371
by: Mr_Ed | last post by:
Hi all, Ok this is a problem we have been having for quite a while and its finally coming to a head.... Ever since we have gone to a Windows 2000 server using IIS5 for our intranet we have had a problem where some but not all users are having problems with websites that used to work perfectly well on a nt4.0 IIS4 server before. The problem we have is that we use NT Authentication to grab the user's login name and then do a lookup to...
1
7315
by: anonymous | last post by:
Hi all, I've been searching the way to achieve the following task. But no luck so far. I have a web site(main site), which requires authentication. This authentication is set at Windows directory level, so user will see the pop up gray box in order to log in rather than custom web page. The username and password are stored at active directory level, thus this is the windows integrated security.
5
2391
by: Matthew Louden | last post by:
I wrote ASP.NET application that access SQL Server database. When I run the application, it yields "Login failed for user '<COMPUTER_NAME>\ASPNET'" error message. I then did the following, but still didn't work. Any ideas?? 1. In IIS console, right click the virtual directory 2. click directory security tab 3. click edit button on anonymous access 4. click browse button
4
2314
by: Zachary Hilbun | last post by:
I need to write an ASP that requires a user to give a User Name and Password to run it. Whenever I've used this on the Web it displays a standard dialog and then offers to save the User Name and Password on my computer so that I don't have to enter it again. How is it that this standard dialog is displayed? Does the ASP (in my case C#) do this or does the Web Server do this and the ASP never knows about it? ...
2
937
by: BillGatesFan | last post by:
Maybe I'm doing this the wrong way. I have an application that you log into and it validates the username and password with the database using a stored proc and if the username and password is valid then it redirects them. But I'm not using any Forms Authentication. It looks better but its pretty much doing the same thing. Is it for if you are logging in to a site? Or can it be used to log into one application? Thanks
0
1056
by: shil | last post by:
Hi, Is there any possibility to authenticate an user between two websites? I have a website through which users login and get authenticated. In the same website I link to a different website and would like to pass userid to the second website. My question is I want to restrict users from going to the second website directly without getting authenticated from the first one. Is this possible? I know we can do this using Forms...
9
15537
by: webrod | last post by:
Hi all, how can I check a user/password in a LDAP ? I don't want to connect with this user, I would like to connect to LDAP with a ADMIN_LOG/ADMIN_PWD, then do a query to find the user and check the password. The thing is I can't access the password attribute to compare with the user's password provided.
4
9818
by: semi_evil | last post by:
I found a nice example of ebay login using PHP and cURL at http://curl.haxx.se/libcurl/php/examples/ Is this technique applicable to sites that authenticate users using a browser-opened dialog? (like .htaccess user validation) The ebay example is a lot to take in for a newbie like me, so I'd like to have an idea first whether it is worth the time and effort modifying it.
14
3271
by: chromis | last post by:
Hi, I've been trying to implement a more OOP oriented approach to dealing with user security on one of my websites, and I am trying to validate the user against an array of roles, however I am struggling with a type error: The argument ROLES passed to function setRoles() is not of type array. If the component name is specified as a type of this argument, the reason for this error might be that a definition file for such component...
0
9716
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10609
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10366
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10105
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7646
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6876
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5677
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4323
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3845
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.