Simulate captive login with greasemonkey using firefox saved password - firefox-addon

I have written GreaseMonkey script to automate captive portal login.
document.getElementById("username").value="myUserName";
document.getElementById("passwd").value=B64.encode("myPassword");
document.form.submit();
Browser's inbuilt password manager can log me into web-based captive portal only if I'm on actual captive login URL. (say http://192.168.1.1/login.html). But what if login-page appears while I am on stackoverflow.com. In this case, I need to enter my password, then I get redirected to same page which I was on, and foolish browser offers me to save password for stackoverflow.com
Is there any way to programmatically retrieve passwords from browser password manager. I found LastPass can retrieve my stored passwords in this way.
What I wanted to achieve?
Auto-Login (without need of hitting login button)
Using Browser's inbuilt password manager.( I can set master password, I can use Sync)
Make browser able to detect captive login page. (Using #include *, in greasemonkey script)
Dont want to save password in plain-text.

Related

Google API auth2 SignIn: Enforce user to enter password every time

I am using google JavaScript sign-in for web site in our web application. Everything is working the way it is supposed to be, however i would like to force the user to enter his password every time whenever he selects google sign-in method. At the moment, google password prompt is skipped, if same user is signed in chrome or in same browser.
Kindly confirm if it is do-able and how.

What is the simplest login access control method for a jquery mobile application that Safari iOS can remember the username and password?

I tried using htpasswd but Safari on iOS does not allow for remembering of username and password.
Is there a script somewhere that may be of use? Or do I need to set up a mysql database.
the username:password#mysite.com solution is not ideal unfortunately.

How does IOS fulfill wifi captive portal auto-login?

It is a very useful function. I am curious about how engineers fulfill it.
There are different log-in pages from different wifi hotspots.I think HTTP POST with one username and one password can log in. But how to make it with compatibility?
Many captive portals use WISPr.
How this works is that the HTML that comes back from the captive portal contains a piece of XML whose format is specified by the WISPr 'standard'. In there there's a login URL, logout URL and other stuff.
The captive portal generates this HTML no matter which URL you're trying to load from your app.
By sending username and password to the supplied login URL result in internet access.

How to parse a web page that has login and password to enter in to view user's personal page? (iphone)

How do I parse a webpage with login and password requirements to view the individual user's information, like facebook for example. I want my app to access to the individual facebook page, after entering login and password in the app.
By now I was able to parse usual webpages with TFHpple, but I have no idea how to pass the login and password requirements to get the page content.
Thank you very much in advance!
Usually the process for logging in is:
User POSTs data to a login form with username and password.
The server responds with a session cookie
Future requests include the session cookie and the server knows that the user is authenticated.
If you wan to do this login process on your user's behalf through our app, you'll need to save the cookies and send them on subsequent requests.
Why don't you use the Facebook iOS SDK:
https://developers.facebook.com/docs/ios/
I think it's a little bit strange from the architecture perspective that you want to parse the personal Facebook newsfeed, when there's the possibility to get the data via the Facebook API (given that you have the appropriate User Permission)...

Passing credentials to Safari from iOS app

I am working on an iOS app in Monotouch. Part of it is to connect to an exchange server and download a list of emails. I would like to include the ability to open the email in the OWA client as well (so I don't have to recreate a email client to provide features OWA gives me for free).
I don't want the user to have to input credentials again however. Opening OWA in safari would usually present the user with either a form or a pop up asking for username and password.
Say I have a user admin with password password1. Currently what I do is request safari to open a link in the following form:
https://admin:password1#mailserver/exchange
This passes the credentials to safari and bypasses the HTTP basic authentication that OWA would usually pop up, however it is not very safe and safari complains of a possible phishing attack.
What other options are there for performing this kind of bypass of HTTP basic authentication?
I would recommend using HttpWebRequest to download each page and set the UIWebView's text manually. Using HttpWebRequest gives you the flexibility to use whatever cookies, credentials, http headers, etc. you want.
This will be tricky, but probably the only way to safely get the credentials in there. Not sure if your OWA app will be able to handle it either.

Resources