Facebook Login Button with redirection - javascript

i recently started working on a project that it required a Facebook login button.
I have successfully set up the button apart from the part where I must redirect the user to my dashboard area which must only be accessible to registered users.
From my understanding I need to fill this field here in the developers facebook settings page
which will redirect the user to my dashboard. I am guessing that the redirection link must include a token which will login the user automatically in my dashboard. Am I right so far?
My concern is if that link can be accessed by anyone and if someone get their hands on it can use it to login to my app without registering.

Related

Github Pages Not Letting Me Redirect

I am creating a little website for guests visiting my home.
Everybody's always asking 'What's the wifi?' - I am sick of that so I am creating a web page for this!
I have created a website page, it requests the user to input a password. I will tell my guest the password for that website page. They submit the password, and it redirects them to a page with my wifi's name and password.
So, I created a GitHub Page with the wifi details and then made the login page but whenever the user clicks the login button, they get returned the 405 Error.
I thought about this for a few hours and decided to not use Github Pages for the login page only. When they click login and it is the correct password, it redirects perfectly! Is this an issue with GitHub Pages or have I done something wrong? I feel like this is not articulate enough so I am happy to further explain if you wish to!

Redirect back to application and display custom error page when user fails to sign in to Okta

I am using Okta for authentication within an Angular app. When the user visits the application they are taking to the https://dev-111111.oktapreview.com/login/login.htm login form. If the user signs in successfully they are taken back to the application which is perfect. However, if the user fails to login the Okta login form says Sign in failed!.
I prefer that instead of the form saying this, that the user is taken back to the application so I can display a custom error page.
Is this possible?

Facebook API: Login only for API ID owner

I try to build a web application that, through it, I can publish post on Facebook.
Problems come out when i wanna log the user without showing login popup, but only insert text and send message, without that nuisance.
But the login popup it's useful for provide use of my app to all user Facebook.
This app it's exclusive for one person, so i don't need that all user Facebook use my app. So I thought a login in function only for API ID/KEY owner
It's possible?

Facebook api not passing user info to integrated site, if user already logged into facebook directly and try to login from integrated site

I am working on login with facebook into our site. I am using facebook js sdk for this. Now, if I clicked on fb login button (which is placed in our site), it opens a popup window asking for user name and password. If I login here by entering correct username and password, its logging in, after that, it gives the required info to me. so, I am passing that info into our site and logging the user. No issue in this flow. But, if user already logged into facebook directly by opening facebook.com from browser and opened our site in separate tab . Our site will also contains "login with facebook" button. So, when user clicks on this button, it opens a login window and closes immediately without giving any user info. I guess it is because, user already logged into facebook. But here also I need the logged in user info. How do I achieve this?
Please help me out.
Any help would be appreciable.

How to logout user from the Facebook when he does not authorize the application

I have ASP.NET web application that
Runs on public computers
Allows users to register by using their Facebook accounts.
Must always logout a user from the Facebook after registration has been completed.
Registration process contains the following steps:
Registration page is shown with the Facebook icon.
When user clicks on the Facebook icon, he is redirected to the Facebook web site.
On the Facebook site user enters his email and password and clicks login.
On the Facebook site user clicks Allow to authorize my application.
User is redirected to my application.
The application registers used in the database.
The application calls FB.logout in order to logout from the Facebook. So when new user starts registration he cannot use account of previous user.
The application works perfect until user clicks Cancel at step 4.
When this happens, the browser is redirected to my application, the user remains signed into the Facebook but the application is not authorized by this user. This means that the application cannot logout this user from the Facebook by using the FB.logout method because the application does not have access token.
How to logout from the Facebook in this case?
Thank you.
How to logout from the Facebook in this case?
Not possible at all.
If logging a user out without a valid access token was possible, then every website I’m visiting could do that if they liked – I’m sure you can see how annoying that’d be to users, and that it’s therefor not possible.

Categories

Resources