incognito mode issue return with not found - google-chrome

URL in incognito mode reply with Not Found The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.
but the same URL can access in normal mode in three browsers chrome,firefox and edge.
what is the reason can make this issue and how can i resolve it?

Assuming you have multiple database in your Odoo instance, on incognito mode when you are tying to load the url, as the controller isn't bound to any DB in the session yet, you are getting that error. It's working on normal browser because on that session you have a DB bound to it.

Related

How to get through security error pages in firefox browser?

I'm aware that we use thisisunsafe in Chrome to bypass such error pages but how can I bypass such pages in Firefox?
I get the following error when I load the page:-
Firefox detected a potential security threat and did not continue to <site> because this website requires a secure connection.
<site> has a security policy called HTTP Strict Transport Security (HSTS), which means that Firefox can only connect to it securely. You can’t add an exception to visit this site.
I tried the following steps to resolve it but it didn't solve the issue:-
Opened a new tab and entered about:config
Clicked on Accept the Risk and Continue
In the search field, type in security.enterprise_roots.enabled and hit enter
I saw one field which was already enabled true
Didn't know what to do next as the field was already enabled true
I'm looking for a workaround of thisisunsafe in Firefox.
In the Mozilla Firefox address bar, type about:config
Look for network.stricttransportsecurity.preloadlist
And set the last field Value to false and restart the browser.
As of April 5th, 2022, this is how I bypass the You can’t add an exception to visit this site. with Firefox 98.
If you see this without the Add Exception button :
Open the Preferences of Firefox:
Open the Privacy & Security tab:
Scroll down to Certificates and click on View Certificates...
Open the Servers tab and click on Add Exception...
Fill in the Location field and click on Get Certificate:
Click on Confirm Security Exception:
You should now see your exception, click on Ok:
Reload your page and you should now be able to see your website :)

CORS still working after disabling browser web security

So I have been testing a website using Selenium, specifically a page with a credit card form embedded in an iframe. I want to access the content of said iframe but due to CORS I get the error message:
Uncaught DOMException: Blocked a frame with origin "<url>" from accessing a cross-origin frame.
I made a quick google search and realized you can bypass CORS using the "--disable-web-security" flag, so my code now looks like the following:
options = webdriver.ChromeOptions()
options.add_argument("--disable-web-security")
self.driver = webdriver.Chrome(os.getenv("CHROME_DRIVER"), options=options)
Surprisingly, the CORS exception keeps on popping and I'm currently stuck on how to go from here. I really do have to access the iframe's content, there isn't a workaround for this.
Since I was confused as to why this didn't work, I replicated the problem with another website, in this case Amazon, which functions similarly (credit card form embedded in an iframe). I ran the code with web security enabled and I get the same CORS error, as expected. But then I disable web security, exactly as mentioned before, and it works! I can now access the iframe.
I also downgraded to an older version of Chrome (86) from the current most stable (88) and nothing happens again. I'm using Ubuntu 20.04.
So now I'm wondering - why isn't the flag working for the first scenario I mentioned? Is there a chance the first website is forcing the browser's web security or something related? I'm not an expert in web development so any input on this would be valuable.
Turns out, all I needed was to add --disable-site-isolation-trials and a non-empty --user-data-dir along with --disable-web-security as stated here
For me, adding these flags to my Chrome launcher fixed my CORS issues:
--disable-web-security --user-data-dir=~/chromeTemp
Pls note, this only turns warnings off, this is definitely not a CORS solution

Chrome ERR_EMPTY_RESPONSE

I have a problem with chrome which don't display some of my static files (css, js mainly). it says that an empty response has been sent by the server
but when I try to "curl" the same URL, it works
I don't really know what's wrong here. I tried disabling cache, clearing all type of cache, incognito mode, disabling chrome extensions... none of those worked
thanks
update
If I try to access the same URL with a random parameter in query string (let's say ?id=1), it works but only once ! when I refresh the page, I get the same error, and so on...
I finally found the problem :
I had something wrong in my .htaccess file. I had module_deflate which wasn't enabled in my apache configuration, so somehow, this prevented my local website to work properly. Just enabled it in my /etc/apache/http.conf and that's it.
If you get the same problem, I would recommend to comment all your .htaccess lines and then uncomment them one by one to see if any of them can cause the problem.
hope this would help someone else.

Watir Webdriver +Chromedriver: ADFS Authentication

I'm attempting to load a page that does a call to ADFS for authentication purposes. On the page load, there is a redirect and then popup to enter credentials.
HTTPS must be used.
Chrome must be used as the testing browser.
So, when loading the page everything is working fine, but I'm forced to manually enter credentials when running the test. After inputting the credentials everything is fine, but is there a way to leverage Watir to input this for me? I've tried popping the username:password into the link already with no success, and since I really need to use Chrome the Firefox plugins are moot.
require 'watir-webdriver'
b = Watir::Browser.new :chrome
b.goto 'https://internalUAT.clientwebsite.com/'
b.link(:text => 'HR Dashboard').click
I'm not allowed to post images due to reputation constraints, but please visit
https://i.imgur.com/ExVt8fp.png
for a screenshot.
When you try passing credentials with the https://user:pass#foo.com technique, do you have any unusual characters in the username or password? (Maybe you have a DOMAIN\username domain prefix?)
If so you might want to make sure any such characters in the credential string are properly escaped.
If that's not the problem, and there's no other way to disable the auth prompt for your tests, then your best bet (IMO) is to write a separate script (or thread) that uses RAutomation (or some other UI automation library of your choosing) to enter your credentials and click the Log In button.
See https://github.com/jarmo/RAutomation
The test cases in the following file contain examples of using RAutomation's send_keys method, which could prove useful:
https://github.com/jarmo/RAutomation/blob/master/spec/window_spec.rb
For the record, it looks like RAutomation may have been used by watir-classic for dialog handling:
https://github.com/watir/watir-classic/blob/master/lib/watir-classic/modal_dialog.rb
http://www.rubydoc.info/github/watir/watir-classic/Watir/ModalDialog

SSRS Chrome/IE Error

We are having issues loading our report server in both IE and Chrome; for some reason, it only works properly in Firefox.
When we try to load it in Chrome, we receive this error:
This webpage is not available
Hide details
The webpage at http://database/reports might be temporarily down or it may have moved permanently to a new web address.
Error code: ERR_INVALID_AUTH_CREDENTIALS
When we try to load it in IE, it circles through the authentication page three times and just dies.
Thanks to anyone with any insight!
It appears that SSO is failing and you might need to register an SPN for your SSRS server:
https://msdn.microsoft.com/en-us/library/cc281382.aspx