Chrome only works on the first session for multi-session logins - google-chrome

I haven't found anything looking like a good answer to my problem, so I'll articulate my own question:
On a Terminal-/Remote Desktop Server (2012 R2), we have a problem running Chrome where there are multiple sessions for the same user. (e.g. a shared "Front Desk" AD user where 2 or 3 people at work may be logged into 4 or 5 RDP sessions with the same user account)
The first launch of Chrome works fine for whichever session opens it. None of the other sessions can use Chrome, however, at least not until the initially launched program instance is closed.
I found an explanation followed by a very unsexy suggestion in the Chromium forums (https://code.google.com/p/chromium/issues/detail?id=160676), so I'm trying to ask here instead in hope that there is a better and more intuitive solution to the problem.
Thank you!

I've solved by, for each concurrent session needed:
In chrome click on Manage people, then Add person, checking Create a desktop shortcut for this user.
Chrome will create a desktop shortcut with the Target property such as:
"C:\......\chrome.exe" --profile-directory="Profile 1"
Edit the Target property of the created desktop shortcut and add a unique folder value for the --user-data parameter:
"C:\......\chrome.exe" --profile-directory="Profile 1" --user-data-dir="C:\temp\user1"

I don't see your log or any other trace clue.
One of my guess chrome's user data directory was locked by the chrome opened.
You might try open the chrome from cmd with this command:
chrome.exe --user-data-dir="C:\temp\user1"
It is starting chrome with a new user data directory.

Workaround details for this issue are here:
https://code.google.com/p/chromium/issues/detail?id=160676

You may want to uncheck the option that lets Chrome run in the background even if "closed"
Click on the Chrome menu (or press Alt+E) Select Settings Click on the link titled ‘Show advanced settings‘ Under the section headed ‘System‘ untick the box next to “Continue running background apps when Google Chrome is closed”

Related

Force "Add to homescreen" prompt a second time on chrome

I am trying to build a PWA. I managed to trigger the prompt a first time and installed the app on my shell (desktop). I then deleted it and I would like to force the prompt to reappear (for debug purpose) but it won't.
I set my chome flag Bypass user engagement checks to enabled, but there's still nothing I can do to trigger the prompt.
When I click on the console setting Application>Manifest>Add to homescreen, nothing happens and I don't receive any error message either.
It's exactly the same code that worked the first time. I just want to trigger it again now that the desktop shortcut has been deleted.
Also struggled with this issue.
At last found that going to chrome://apps/ and removing the app will enable to re-add it
If the chrome://flags/#bypass-app-banner-engagement-checks flag is enabled and you are still not getting the banner, its high likely one of PWA criteria is not met anymore.
It might have worked before. But with the changing code, something might have went wrong with Service worker, accessing via HTTP instead of HTTPS or having an invalid certificate kind if issues might have made your app not eligible for App install banner.
Validate: Validate your current sites PWA eligibility using Chrome Developer tools -> Audits -> Perform Audit -> Progressive Web App. See if all goes through regarding PWA criteria and if you see all looks good and still you don't get the Install Banner, post the Audit screenshot to give us some idea on whats going on.
You can just also just set it in the Developer Tools under Application by checking on Update on reload or click on Unregister to completely remove the SW. Dirty, but does the trick all the time.

How to turn off windows integrated authentication in Chrome

I used to be able to disable windows integrated authentication by updating the settings in IE. Recently this no longer works. Has something changed in recent versions of chrome? Is there a new way to turn this off?
Chrome version 46.0.2490.71
I used to use this setting in IE
Internet Options -> Advanced -> uncheck 'Enable Windows Integrated Authentication'
I got this response from an internal admin and it seems to work.
I think the best we came up with was to create a shortcut to
chrome.exe on your desktop and modify the target of the shortcut to be
something like:
"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --auth-server-whitelist="_"
Edit: Corrected the path for misplaced backslashes. Note also the (x86), just in case.
Expanding on Daniel Trimble's answer, which worked for me:
I would like to help more people find this useful answer by adding a little more context. What is Integrated Windows Authentication, and why would you want to disable it?
Basically, Integrated Windows Authentication allows a browser such as Chrome to access credentials that are stored on your computer (for example, the password you use to log into your office computer) and use those same credentials to log you into a website (for example, a password-protected portion of your company's website). This occurs behind the scenes, without a visible password prompt.
The problem is that you may not want to be automatically logged into a particular website.
Example: I like to use Chrome as a test browser to see the "public" view of my company's website. Generally I log into our site in Firefox or IE, make changes there, and then view the site in Chrome to make sure my changes were "published" as intended.
Suddenly, one day, I could no longer stay signed out of my company's website in Chrome. Whenever I navigated to a password-protected page, instead of giving me a login prompt, Chrome would automatically sign me in to Microsoft SharePoint (my company's content-management system) and show me the "logged in" version of that page.
If something similar is happening to you, there are other, more obvious things you should try first. Start by clearing your saved passwords (Chrome menu button > Settings > Show advanced settings > Passwords and forms > Manage passwords).
Clearing my saved passwords didn't work for me, so I tried other things: cleared the cache, removed all cookies, reset Chrome's settings, uninstalled and reinstalled Chrome. I even visited a password-protected page in an Incognito window, but Chrome still signed me in automatically.
Finally I found this Stack Overflow page, which solved the problem. (Thank you, Daniel Trimble!) Integrated Windows Authentication was the culprit. IWA used to be turned off by default in Chrome; you had to enable it via a checkbox in your Internet Options (shared with IE). At some point in the recent past, Google apparently decided to enable IWA by default. The unfortunate part is that they did not provide an option under Chrome's Settings panel to disable it. At least there's this workaround!
How to disable Integrated Windows Authentication (IWA) for Chrome via Windows' Control Panel:
(This applies to both Internet Explorer and Chrome since Chrome uses system settings that are managed using Internet Explorer.)
Press Windows' Start button, type "Internet Options" to search, and click the one result, from the control panel
Go to the "Security" tab
Select "Local Intranet" and click on "Custom Level" button
Scroll to the "User Authentication" section at the bottom of the list and select "Prompt for user name and password"
Click Ok, Apply, and Ok to save changes
Close all instances of the IE browser to make the changes effective. Launch the browser again and access the application. A basic authentication challenge will be served.
Source: https://sso.cisco.com/autho/msgs/disable_IWA.htm
I found out we had a windows policy that set the following registry key:
HKEY_CURRENT_USER\Software\Policies\Google\Chrome\AuthServerWhitelist
Deleting this key made Chrome prompt for a username and password for me.
More information about the registry keys.
Great and all the above answers work perfect.!
To add more -- I found that google chrome (version 68.0.3440.106) has the GUI option for Windows integrated authentication, just like in IE, this worked for me :)
goto chrome://settings/
Show advanced settings...
In the "Network" section, click on "Change proxy settings..."
Chrome opens the internet properties window
in the security tab
Select Local Intranet and Click on "Custom Level" button
Scroll to bottom of the window to User Authentication section, select "Prompt for user name and password"
Click Ok, Apply and Ok to save changes.
close existing session and start a new chrome session.

"Chrome legacy Window" when launching chrome with RunAs

I am trying to use MSAA (on Win7) to get the addressbar in chrome browser and replace it with a different url. When chrome is launched normally (as the loggedon user), I am able to find the addressbar using the IAccessible interface by traversing through the UI tree of the window classes owned by the process.
However, if I launch chrome as a different user (by using RunAs in windows), I see window with name, "chrome legacy window" when going through the classes owned by the "RunAs" process. The window hierarchy and the content within is vastly different from what I see if I scan the process that is running as the logged on user.
Although I can see (window classnames) Chrome_WidgetWin_0 & Chrome_WidgetWin_1 in both the browser instances, only the one running as the current user is giving access to the address bar.
Any idea on what is happening when chrome is launched as a different user? Is there any workaround or should I be looking at a different technology?
As Penn has noted this may have something to do with the PDF view which has caused peculiar problems in the strangest of places.
Looking at the bug tracker here it looks like sporadic behaviour with PDFs and the "legacy window" has been introduced in a recent build so perhaps try rolling back to an earlier version of Chrome.
Also I presume you are using chrome://accessibility with
Global accessibility mode: on
Show internal accessibility tree instead of native: on
or starting chrome with the flag --force-renderer-accessibility it seems to be a prerequisite for other automation programs like autoit as seen here.
If you can't get this method working I'd recommend trying the autoit script there.
Here is an autoit code example that shows grabbing the address bar and using it for general navigation, upon other things!
I have found that if a PDF file is open in the chrome viewer (in some versions of chrome) the window you referred to appears. Please confirm what URL is being used when you open chrome.
I have also read that a password request prompt can cause the same window to open. The PDF window only appears if the window is launched by certain processes/users

chrome extension: open an website with different account in each tab

I have several accounts for a website and currently I want to write an extension that I can open all the accounts simultaneously in chrome, each tab for one account.
So that means I want each tab with a separate cookie system, is it doable? If so please suggest the API I should use, thanks!
Go to Chrome Preferences. There is a Users section where you can add users. Each new user will have its own cookie jar, so you can log in to a site as many different users at once. It makes new chrome windows, but it seems you cannot drag a tab onto a window of another user.
According to Chrome documentation, you can modify HTTP headers (including cookies) in the onBeforeSendHeaders event handler. So, you need to store new cookies for every account by means of the onHeadersReceived event handler, and then substitute them for every tab in outgoing requests.
There even exists an extension which seems doing almost the thing you want - Chrome Cookie Switcher.
Also I have found an answer that may be helpful for your task: Associate a custom user agent to a specific Google Chrome page/tab.
I really don't think Chrome allows extensions to do this. If I recall correctly, extensions can inspect and block requests, but they can't modify them, such as changing cookies on the fly for each tab.
I suggest you use the --user-data-dir command-line option of Chrome. It allows you to keep several separate profiles, each in its own directory, and then you only need to start chrome with the proper option:
# run this command to use the first profile
google-chrome --user-data-dir=/home/binchen/my_chrome_profiles/my_profile_1
# run this command to use the second profile
google-chrome --user-data-dir=/home/binchen/my_chrome_profiles/my_profile_2
...
Each profile will be in its own Chrome window, with its own cookie store, instead of its own tab, but it's easier than writing an extension.
Lastly, if the website you're mentioning is Google, you can keep several Google accounts open at the same time.

how can I get different sessionID(windowID) in chrome Incognito mode?

I open a chrome incognito mode window(ctrl+shift+n), and log in:
https://www.google.com/accounts/ManageAccount
now ,I want login another account, I open a new incognito mode window,
but the new window is already logined for last account,
how can I get different windowsID in chrome Incognito mode?
BTW: google.com only a example, I want login another sites,like stackoverflow.com, so ,I want get a different windowID in new chrome window
Isn't it possible to avoid the problem altogether by going to your Account Settings and changing "Multiple sign-in" ?
This would allow you to login to multiple accounts in most Google products.
Here's another interesting link: "Using multiple accounts simultaneously" on Google's own online help.