InternetExplorerDriver not opening site, but user can open it - selenium

I'm working in a highly secured environment. I can only use IE11 by company's policy. I'm trying to implement test automation on my project.
I'm using Selenium and IEDriver.
Currently I'm trying to implement basic scenario by just opening application page.
When I'm trying to do it via IEDriver, the page is not getting opened and the message "This page cannot be displayed" is shown.
But when I open the page manually by just typing in the url to the address bar everything works fine.
I guess it has something to do with the cookies that are coming with the request I'm making manually. Seems like those cookies contain some signature.
Can someone advise me how can I track the problem to resolve it?
Thanks.

Be sure top follow the required configuration section on this site: https://github.com/SeleniumHQ/selenium/wiki/InternetExplorerDriver
I had some issues with IE acting the same way until following this setup.

So the issue was fixed by setting proxy.
Seems like there was a change in security rules recently.

Related

Is there any way to tell recaptcha html component to load using local recaptcha__en.js: instead to looking for it outside?

I have implemented RECAPCHA on my login page using this tutorial and it works great. It makes use of the AspNetCore.ReCaptcha package.
The issue that I'm having is that the recaptcha needs a file named recaptcha__en.js that lives outside, in a Google repository.
I'm working in a VPN that I need to use to connect to my client network, and this VPN blocks the connection to this outside .js. To unblock it or add a specific rule in the VPN, is not an option right now, so I was wondering if there's any way to tell the recaptcha html .NET core component, to read the recaptcha__en.js from my own solution.
I tried to simply include the script in my page, but the component still fails. It insists on searching for the JS outside, even if it is included in the page. If there's a way, it isn't documented anywhere that I'm aware off.
Can you help?
I don't know if you can visit other websites in your VPN at all.
If you can access other sites, you can use reCAPTCHA globally. Using https://www.recaptcha.net/recaptcha/api.js will work fine in your internal network.
If you can't access any sites in your VPN, you can't use reCAPTCHA service in your project, because the Javascript content like https://www.google.com/recaptcha/api.js are not static functions in a file. It's an interactive Google service.

How to implement Google authentication using Xamarin.Forms?

I am developing a login feature in that user can login into the application using the Google account and get user profile detail. For that, I am creating a project in google developers and it's verified by me.
I try with this reference here but when I try with this that is give me the error of "Disallowed user agent" and gives me the error of the open in safari or chrome when I try with the iPhone(iOS devices).
I also go through some other references like "Xamarin. Auth" but it doesn't work for me. When I set a redirection URL with clientId:/oauth2redirect or the Package Name(Bundle Identifier):/oauth2redirect . It gives me an exception of Not valid redirect Uri.
I also try to add JSON and p12 file on respective device-specific projects and set bundle resource but it doesn't work me.
If anyone has solution to this without using WebView than help me.
You can try this plugin from CroosGeeks
https://github.com/CrossGeeks/GoogleClientPlugin
Here is the sample app:
https://github.com/CrossGeeks/GoogleClientPlugin/tree/master/GoogleClient/GoogleClientSample
This is not using the WebView. The documentation is also quite good.

Instagram API Register New Client Not Showing Captcha

So I'm trying to register a new client on the instagram API. I have a business account and have done the proper steps prior to this. Everytime I fill out the "Register New Client ID" form and submit it, I get an error "The captcha solution was not correct. Please try again." But no there is no captcha for me to fill out!! Looking at the console errors it says the CSP page setting's are blocking this source https://www.google.com/recaptcha/api.js. I'm gonna take a wild guess and say that has the captcha I need that's not appearing..lol.
Anyway, I've disabled all my content blocking settings and JS is enabled on firefox (oh I'm using firefox developer edition btw) and no change. I've also tried this in chrome and safari, no change. I don't have this issue with other sites that use captchas.
Anyone have any idea what's going on?
'preciate it!
Had the same issue here on Google Chrome. Used IE11 (version 11.345.17134.0 to be exact), and captcha displayed instantly. I've successfully registered a new client
I suggest to wait until Instagram team realizes to upgrade their whatever scripts & parameters.
I found myself in the same scenario:
I'm logged on Instagram
I land to instagram.com/developer/clients/register/ over Google Chrome 70.0.3538.102 (no extensions)
No captcha. And I get the following from the console:
ps: I tried figuring out how to submit this specific report, but after several searches I find myself loosing too much time... to make them aware.

handle windows login pop-up using selenium web driver for https website

My scenario:
I am opening a https website, I get a login pop-up that is not identified by selenium webdriver. I have searched and found the below link which had similar question.
How to handle login pop up window using Selenium WebDriver?
I tried he solution given by #Pavel Janicek to pass the credentials via URL
It does not working for me, I mean after the browser is opened it keeps processing nothing happens after that.
In my case, it is a https site,i need to give username#domainname & password to login, giving only username will not work
my url looks like this
https://username#domainname:password#sitename.com
Has anyone faced this kind of problem?
Thanks
You can NOT auth with this window(in selenium without any additional framework as Robot). But you can auth without getting this window. Try change URL to: http://user:password#www.yourserveradress.com
if this will not help, you need to create separated profile in browser, pass authentication on this server and remember password and use this profile in selenium. Also I think its possible to use Windows active directory authentication, but cannot sure about details.

Facebook Connect button not showing up in Safari/Chrome

My implementation of Facebook Connect (just a simple login button, fb:login-button) works perfectly on Firefox and IE.
But the same button is not showing up in Safari/Chrome (Webkit).
Here's what's ironic. In my debugging effort, I saved the page (that contains fb:login-button) up as a static page and then load it in Safari. And the button shows up, everything works!
The exact same page (with the exact same HTML source) rendered by my PHP has no way for bringing up the button.
I'm trying hard to support Webkit here but I'm close to giving up. Can anybody help?
I found one more way this can occur (the blame-myself-for-being-stupid way); it's probably not common, but in the event is saves anyone else the hassle, here it is:
This symptom can also be caused by various security tools blocking facebook resources.
In my case, I'd installed Facebook Disconnect ages ago in Chrome as a plugin and forgotten all about it being installed. I also had a second installation of Chrome that was seemingly identical (but did not have Facebook Disconnect). The first would properly load the fb:login-button, and the other would not; took me ages before I looked at the plugins, because Facebook Disconnect didn't have an icon and so its presence was pretty easy for me to miss.
Here's what you'll see if some sort of security plugin is preventing facebook resources from loading. Just look at the html that renders in the browser using developer tools.
In a normal chrome session you'll end up with something like this:
<fb:login-button><a class="fb_button fb_button_medium"><span class="fb_button_text">Your text here</span></a></fb:login-button>
But in the version with facebook's resources disabled you'll end up with this:
<fb:login-button>Your text here</fb:login-button>
Like I said, pretty obvious in retrospect.
Had the same problem but it was not related to anything like a plugin or malformed content. It seems if you enable country filtering on your facebook page it has an issue with the like button, this should be fairly obvious. Facebook gets your location from your profile and not your IP address.
Make sure to disable country locking if you plan on using the social plugins.
This can be due to having ClickToFlash installed. Either disable it, or check "Automatically load invisible Flash views" in the ClickToFlash settings.
What we found out is that Safari (and maybe some older versions of Chrome or other WebKIT browsers) have a problem with Facebook's code using the innerHTML JS function if your page arrives with an XHTML response header (application/xhtml+xml).
Using text/html solves the issue.
In case of JSF2, which we use, the implementing the fix was as simple as wrapping the FB button like this:
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:fb="http://www.facebook.com/2008/fbml"
xmlns:f="http://java.sun.com/jsf/core">
...
<f:view contentType="text/html">
<fb:login-button>Login using Facebook</fb:login-button>
</f:view>
Facebook bug report here:
http://bugs.developers.facebook.net/show_bug.cgi?id=5545
I had this problem with the Facebook button not showing at all and it took me forever to figure out what it was. Luckily after days of hair pulling I will now share the answer with everyone. In my situation I simply didn't have xfbml enabled. In my FB.init I had it set to false:
FB.init({
appId : 'app_id', // App ID
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : false, // parse XFBML
oauth : true // enable OAuth 2.0
});
I changed this to "true" (xfbml) and the login buttons works great now! :P Good luck!
This happened when I had the wrong domain in callback_url in config/facebooker.yml. Apparently it uses that to load the js files.
I had the same problem but I resolved it by making sure the URL in my app settings was exactly the same as the one for my site (i.e. it didn't work when I accessed my site without the www.).
I have tried every suggested solution here and it didn't work for me. But now I finally found the solution.
Facebook requires now a secured (https) for Canvas (Secure Canvas URL). The unsecured one will be deprecated soon.
Here is the main difference, Chrome doesn't like https connections with invalid certifications. On a localhost, it is very likely you have stunnel installed to allow https connection for the localhost. Firefox is ok with the self created SSL certificate and allows you to add an exception when trying to access that site. Chrome doesn't allow it out of the box.
When I load my app in Chrome the page is blank and I dont see any login button.
Click F12 and click the Netwrok tab in Chrome:
You see that the post request to your localhost is cancelled. DOUBLE Click on it.
Now you would see that chrome is blocking the localhost because of the certificate:
click on proceed anyway.
Now to back to your other tab and reload the page:
Chrome works now like Firefox and shows the login button.