State Management :: Passing UserID Between Two Websites In A Secure Way?

Jul 28, 2010

I have two websites one in ASP.Net and other in PHP.I want that if a person logged in on one website then he gets a link for second website. When he/she click on that link his userID is passed to second site. If i am using query string then it is security lack. Can I use web Services for that. How I make web service secure. Is there are other way of doing this.

View 8 Replies


Similar Messages:

State Management :: Passing Variables From One Site To Secure Site?

Jul 28, 2010

I have 2 sites, one the main product site the other a secure site featuring the basket and checkout processes.

When a user clicks "add item to basket" I am creating a basket in a database and then adding the items to the basket. The theory was then to store the id from the database for the basket (the basketid) in a cookie, redirect the user to secure site, use the basket id from the cookie and display the contents in the basket.

However I am having trouble getting the secure site to use the same cookie. When I redirect the users to the secure site, the basket appears empty. I need to go back to the main site and then back to secure before the cookie appears.

Here is the code for the cookie

[Code]....

And then on the secure site this is how it gets the basket ID from the cookie

[Code]....

But like I say it's having problems. I've tried replacing the cookies with session variables as well but it didn't work.

View 1 Replies

State Management :: Session Sharing Between Two Websites?

Aug 13, 2010

I have a website A which has a link to website B which is currently opening in a different window. When clicked on a link to, the login for B is automatically taken care of as both the websites have same user login credentials.

Now a change in the system has made me embed website B into website A. ie., B will open in the same window of A.. I could achieve this using an IFrame. Now, the session from site A needs to be carried out to site B. Presently, when navigated from A to B, all the sessions on A expire. Once navigated to B the session time out of B from the webconfig is taken. I have used "InProc" as my state management option in web config. Is it possible to maintain single session for both the webistes? If not how to continue same session times for both webistes? I do not want to use "SQL server" state mode.

View 4 Replies

State Management :: Get Username According To Userid & Use On Separate Web Forms In Website?

Oct 3, 2010

i 'm creating a website. i create a login form. after login my session will be start and all page of user profile will check first is session istart. i have stored userid in session for identify user. But i want to username of that userid. Remaiber username and userid are different. and i want to show only username on welcome tab.

e.g. userid= rksaini89
username= ramkrishn

so i want to show like this "welcome ramkrishn" on my home page and other many places on different forms. my confusion is that how to get username acording userid and where to keep store it. i can get it from database according session but i'm confused where to keep it so i can use it everywhere on my website.

View 1 Replies

State Management :: Get The Calling Url Referrer From A Secure Site?

Jul 14, 2010

I need to get the calling page url referrer and host name. I works for me if the calling pages are within the same network. When a page is called from an internal site that are outside of my network, I got the following error:

Object reference not set to an instance of an object.

It failed on this line:

string userURL = Request.UrlReferrer.ToString();

View 1 Replies

State Management :: Secure Query String Or Session Variable

Aug 30, 2010

Example scenario:
User login has a list of associated 'accounts' it has access to... this list of accounts is stored in a database table, say tblAccountAccessControl, something like:

login, accountID
userA, account123
userA, account456
userA, account798
userB, accountABC
userB, accountDEF
etc..

This info is used throughout the web application and determines the 'domain' of information the particular login has access to. For example there are many other tables that have the 'accountID' field and whenever a page pulls data from the table it only pulls data that the currently logged in user should be allowed to see, based on that tblAccountAccessControl data.

The security question:
Do I need to query the database every time I need to get this list of allowed accountID's? I was about to use a plain old query string to pass a particular accountID to another page but quickly caught myself as I realized that would be a major security flaw (the receiving page was going to use that accountID to grab info from the database, and there would be nothing preventing a user from simply typing in a url manually to get data from an accountID they are not supposed to be allowed to view). So I then thought I'll just store the list of accountID's in a session state variable so they will be carried with the user throughout the session.

But then I remembered there are tools out there that allow you to easily intercept and modify asp.net viewstate information and I'm not sure if that would included session state variables, but I'm guessing they would. Is there a way to create a secure query string? If I used session state would that session state information be exposed and modifyable by utilities out there? Am I just stuck having to query the database every time I need this info to assure security? What about encrypting it and then storing in session state variable (just thought of that one)?

View 5 Replies

State Management :: ReNew Life Time Of The Session Of Page.User.Identity.UserId?

Feb 23, 2011

i have Using aspnetmembership

i want to know how i can ReNew The Life Time Of Page.User.Identity.UserId Session, , how i can increase the Time Of this session ??

i want this scenario in case when the user LogOn for 15 minutes , then the page refreshed ,then renew the TimeOut Of Session by adding addtional 15 minutes and so on

note that im using Page.User.Identity.UserId Session

View 2 Replies

State Management :: When Redirect The Users To The Secure Site, The Basket Appears Empty?

Oct 1, 2010

I have 2 sites, one the main product site the other a secure site featuring the basket and checkout processes.

When a user clicks "add item to basket" I am creating a basket in a database and then adding the items to the basket. The theory was then to store the id from the database for the basket (the basketid) in a cookie, redirect the user to secure site, use the basket id from the cookie and display the contents in the basket.

However I am having trouble getting the secure site to use the same cookie. When I redirect the users to the secure site, the basket appears empty. I need to go back to the main site and then back to secure before the cookie appears.

Here is the code for the cookie

[Code]....

And then on the secure site this is how it gets the basket ID from the cookie

[Code]....

But like I say it's having problems. I've tried replacing the cookies with session variables as well but it didn't work.

View 6 Replies

State Management :: Public Variable Vs Session Variable To Store Logged In UserID

May 17, 2010

I have a web application which uses a session variable to store the logged in userid. If no user is logged in, of course this variable will be empty and the contents displayed on my website are meant for guests. If there is a user logged in, the user specific controls/access/links will then be a displayed.

I am now having issues with my hosting where on shared application pool, the worker recycle is triggered every 90 minutes, this will clear sessions causing all my users to be logged out. I opted for a dedicated application pool, which got worse because I am only allocated 50MB memory limit and if this is reached, the worker recycle is triggered and I lose my sessions again. I have tried as much as possible optimization techniques, e.g. dispose where possible, close connections, disable viewstate for static controls etc but my memory per instance keeps building up from page to page without any signs of improvement. I don't use loops nor store huge objects like bitmaps etc but my sessions are now gone even faster than 90 minutes in shared application pool before.

I have considered using SQL Session State but there isn't a simple guide on using this with MySQL. I am getting desperate and considering using a public variable, a string as a replacement to store logged in user id instead of in a session variable. I am pretty sure this will solve my issue with sessions being recycled but are there any negative consequences of doing this? One problem I can think of is if the user closes the browser, the system will never know that the user is now logged out and this public variable should be nothing. In this scenario, will the GC eventually clear this abandoned public variable.

View 10 Replies

State Management :: Passing Value Of A Text Box To Another Page

Dec 4, 2010

I have a text box and a asp button in master page, i just want to use the value of the text box on the target page. i have set the post back url of the asp button.on the page load event of the target page i write the following code

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
If Not isPostback Then
Try [code]...

this is not working. i could not get the value of txtSearch.

View 3 Replies

State Management :: Passing The Variable To Another Page?

May 3, 2010

want to use the value of a variable on to the other page, what i am supposed to do for that.i am novice at asp.net

View 8 Replies

State Management :: Passing Session In Web Service?

Mar 26, 2011

I have a number saved in session and am using it in a bunch of pages right now, and I was wondering if I could somehow access this session in my WebService.asmx file? It would be great since then that way I can fix my auto complete extender. I know I can use contextKey, but I am using that contextKey for something else. If session isn't possible in web service, then is it possible to use two contextkeys in auto complete extender, and how?

View 1 Replies

State Management :: Passing Guid Value In Querystring?

Oct 4, 2010

trying to pass a guid value to querystring - it should take the guid value from one page to another. i get an error: value cannot be null, parameter name: g. so my guid value is not being pass to my second page. below is code:

Page one:

static Guid g = Guid.Empty;

public static string userID = g.ToString();
string userName = string.Empty;

[code]...

View 2 Replies

State Management :: Passing Values In Pages?

Aug 20, 2010

how to pass the value from one page to another page in asp.net with out Using State Management Concepts?
Like 1. cookies 2.Sessiion 3. QueryStrings.With out using the above should pass the values..

View 4 Replies

State Management :: Passing Form Data Between Pages?

Oct 8, 2010

I have to split a long form into two pages. In the first page, I have a button "Next Page" to second page and in second page, a button "Previous page" to go to first page. How do I keep the form data when click "next page" and "previous page"?

I am using session variables to pass the form data. I have the server control Enableviewstat as true, but it still doesn't work. What else should I do? My code as below:

[Code]....

View 8 Replies

State Management :: Passing Value From One Web Application To Another Hosted In Different Server?

Sep 14, 2010

I want to redirect from one aspx page to another aspx page of different application.Both applications are hosted in different application servers. I want to pass a value from one application to another.I tried - 1. Response.redirect with Query string - But query string is not secure as it is visible to user in browser.2. Cookies - This is also not a secure way. Again if the cookies are disable in the browser it may not work.3. Server.transfer - In different web application we cant use server.transfer.Please provide any easy solution how to achieve this. I dont want to display the values to the user as it is confidential data.

View 13 Replies

State Management :: Passing Querystring To User Control?

Aug 6, 2010

I have a aspx page and there is a web user control that must load dynamically with the data related to the aspx page....

ok so I want to use a querystring and pass it to the web user control.....how do I do this?

then also how do I pass a querystring from a web user control back to a aspx page?

This is a question I always had...and therefore never actually started to use the web user control

View 5 Replies

State Management :: Gridview Checkbox Passing To New Page

Oct 14, 2010

I have searched and searched and unable to find an easy to understand answer with a sample of what I am after. Apologies I am new to ASP and programming VB.

View 5 Replies

State Management :: Passing Multiple Parameters Value From A Window To Another?

Jul 29, 2010

I have a parameter screen which contains many pop up windows for the parameters .

I have a department hierarchy which consists of department , branch and section.

I have 3 pop up windows for each parameter.

When i select, a department, it filters the list of the branch and shows only its branch when i open the branch pop up window.

But the problem is, when i select multiple departments, the branch pop up window shows the below error. The page works if only a department is shown.

Conversion failed when converting the nvarchar value '3,4,5,6 to data type int. Description: An unhandled exception occurred during the execution of the current web request. review the stack trace for more information about the error and where it originated in the code.

My code for the branch page is :

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Branch.aspx.cs" Inherits="Modules_Reports_Branch" Title="Select Branch"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">

[Code]....

View 4 Replies

State Management :: Passing A Unique ID To The Next Load Page?

Jul 7, 2010

I am using a FormView and on insert I want it to be redirected to another page and take the ID of the FormView which I have just inserted so I can have page b load with the date from page a that I have just inserted

View 3 Replies

State Management :: Session Or Request In Class Without Passing As Parameter

Sep 3, 2010

I'd like to be able to reference the asp.net objects Session, Request, from a procedure without passing them in as parameters all the time. Is there a way to do this. For example, now I have

[Code]....

I'd like to call it like this "ContextPT.GetSession()" and have GetSession know how to find the Session object. I know this does not seem like a big deal in this case, but I have reasons.

View 1 Replies

State Management :: Passing Values From Textbox To Labels On Another Page?

Oct 14, 2010

I have a form with a combination of dropdownlists and textboxes that I want to be able to show a user as a summary in another page before submitting to a sql server. Page 1 will have a verify button which will then pass the dropdown and text box info to page 2 where end users will be able to either submit the page or cancel the action. What's the best way to pass the values from page 1 to page 2?

View 9 Replies

State Management :: Passing Data Client To Server Using Hidden Field

Mar 26, 2010

I am trying to pass data from client to server using a hidden field. If I use a button, then OnClientClick sets the value, and OnClick does the postback and all is well.

However, I am responding to a Client event, and although this works I get no postback. How do I now force a postback from my client handler?

View 3 Replies

State Management :: Passing Multiple Array Values Through A Query String?

Feb 16, 2011

I have a query string which contains the value of more than one Array, I want to pass these values from Page 1 to Page 2 and then distribute the array values into new arrays on Page 2.

Here is what I have so far.

Page 1

[Code]....

[Code]....

Page 2

[Code]....

All that I get returned in EFFinal and IFFinal is System.String?

View 5 Replies

Publishing Websites: DLL Vs Code Behind - Which Is More Secure

Nov 16, 2010

I recently came aware of some knowledge I was not aware of before. One of my friends said that publishing a website with the code behind is a security risk. Instead, he insisted I only publish with the DLL's to prevent hackers from altering your code. Is this true? What are the advantages and disadvantages for doing this?

View 3 Replies







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