Facebook auto-login - asp.net

I have one situation. I create a website. Then I put a tab that will link to Facebook authorization login page. Can I pass login parameter(Email,Password) to the Facebook authorization login page?? So that the user can authorize the application without see the authorization login page.
Thanks.

No. You can't do that. It would require the user to give you their facebook password which obviously would be breaking all kinds of terms and conditions. This is what OAuth is for. Check out the documentation on authentication

Related

Basic authentication auto login but no credentials shows in URL

I am trying to achieve auto login with given credentials in the back while users can directly see a logged in web page so that they don't need to type or know the credentials. Is there a way to do this without any credentials show up in the URL from user's side?
If you only have a link to work with, this is not possible.

Facebook PHP SDK, server-side login, without clicking any link (knowing password).

Can i log in to my Facebook account (Knowing user id and password), in the server using Facebook php-sdk, and without need to click any URL?
If yes, please explain.
It is against Facebook's Terms of Service to use a user's email address and password to login to their account. You should instead use the Facebook API to achieve this, but it requires manual login by a user.
There are ways of achieving automatic login using credentials, but since it's not allowed, I won't go into detail. Facebook also detects and prevents most of the common method of auto-login.

How to pass login userid to all pages when i redirect to any page by clicking menu

I am creating a customer module in asp.net website project. i developed login page and from login page i am entering to customer home page. here i am giving menu items like
customerprofile
2.customerpurchased items
3.customervieweditems
4.customerbiilingpage like
here for every page i need used login id that should come directly in pageload.
please any one help me how to pass login user id to above 4 pages.
You should look into authentication for this site. Search on FormsAuthentication using a FormsAuthenticationTicket, or use the newer Memebership and Roles functionality. Do this properly and you really don't "pass" the login aroun, you read it from the HttpContext.Current.User.Identity container.
why not you use Session ? Session is the best case for your scenario. or if you wanted to use Authentication mechanism, then Go for Membership Provider, FormsAuthentication. How To Implement Simple Forms Authentication
Session["UserID"]=yourUseID;
to retreive
var userID=Session["UserID"].ToStrin();

Facebook login with ASP.NET

I am implementing Facebook login on my website. I am creating an asp.net user as well with the Facebook users details. This way I can control login in people to my site using .NET membership regardless of whether they are a Facebook user or not.
The problem I am facing now is security. When a user logs in with Facebook I am calling a webservice with their facebook details, if the user exists on the system (by their facebook userid) then I log them in. However as it stands anyone could call the webservice with someone elses facebook id and it would log them in (if that user existed on the system). Is there something that I can use to link the facebook user with my asp.net user that is only accessible to that user, such as an access token. It also needs to be something which does not change? Does facebook send back such a thing in the response object?
Any help or suggestions are much appreciated.
Thanks
Yes, we can get that profile data from Facebook. Using that requestAccessToken Url you can get that access token.
requestAccessTokenurl="https://graph.facebook.com/oauth/access_token?client_id={0} redirect_uri={1};client_secret={2};code={3}"
Also we can get the Profile Data using this access token
requestProfileUrl="https://graph.facebook.com/me"
please see this link- http://easyoauth.codeplex.com/
you can download the source code also :)
We have implemented for Facebook, Twitter, LinkedIn, Google using this framework. It is very straight forward. I can help you how to do this.
Thanks

How to login in LinkedIn automatically from asp.net application?

I have dummy username and pasword to enter in linkedin. From an asp.net application, when the button is clicked i need to login automatically used the username and password in linkedIn.
How to do that?
Thanks
A direct (server to server) login is not possible. It wouldn't be nice to ask your users for their LinkedIn account and password.
You can implement OAuth between you (consumer) and LinkedIn (provider) and let the user log directly to LinkedIn. More info about this on:
http://developer.linkedin.com/docs/DOC-1008
By loading your destination URl into a Web-browser element and being redirected, .net would allow handling of the body html and auto click of the login for this.
Alternatively you can pass the header value with the request that would pass through auth - should last 2 days a time I believe.

Resources