Change browser search engine for every user/machine in windows domain - google-chrome

I want every workstation in my school to have Ecosia as their default search engine.
If one wants to change his search engine to Ecosia on his home computer with Firefox he needs to add the extension to his Firefox profile and change his default search engine to the then added option "Ecosia"
But it is hard to do this for every user in our Windows domain automatically.
My easiest option would be to deploy a script to modify the Firefox(Chrome/Edge) installation but didn't find a way to change the configured search engine. Adding the extension seems to be no problem.
Also I can not change anything in the user files as they are not saved locally but on the domain controller. (Otherwise I could just overwrite the users Firefox profiles)
Some of the other options to deploy custom Firefox installers in companies included preinstalled extensions but I haven't found a configuration that included the search engine configuration.
I want to change the search preferences in Firefox, Chrome and Edge. Firefox alone is driving me crazy.
But there must be a way to achieve this as many viruses doing search hijacking change your search engine without problems event though i was not able to find any source code of those.
So in the end the question is:
Is there a way to add an extension and change the search engine of Firefox/Chrome/Edge without touching the user data or is there a way to preconfigure installers to include a different standard search engine?
I'm kinda desperate by now, so any approach is welcome.
To be specific:
My school has about 200 computers with Windows7/Windows10
combined in a windows domain. Each Student has his own account.
The system for distributing software installers/scripts is opsi

If you use Firefox ESR, you can set up search engines via GPO.
You can add a search engine as part of your web extension via chrome_settings_overrides.search_engine in the extension's manifest (example); making it the default will prompt the user.
The way "viruses [are] doing search hijacking change" is probably by storing the search plugin file to searchplugins and updating the user preferences file.

Related

How to remove istartsurf from browser

How to remove istartsurf from chrome?
Context: I've installed a bunch of extensions after a day I got "istartsurf" as my main search engine in chrome which sends the search to their server and then redirects the search to google making it seem like you searched on google from the start. It takes a split second then you only see google.com in the address bar.
I've installed
chrome extensions: Requestly, Toby for Chrome
apps: Java, JDK, postgresql.
Can anyone relate to this? as I want to narrow done the source of this.
For Chrome you need to go to settings > Search engine
For Search engine used in the address bar set Google (or whatever you want)
For Manage search engines go through to the lists and remove anything suspicious.
Similar should be done for other browsers.
If this goes deeper (registry or something else) please let me know so I can update the answer.

How to detect if chrome profile is in use chrome driver

We have an internal company utility that can open our internal sites through various browsers using the various browser drivers (iexplore, geckodriver, chromedriver).
One of the options for the chromedriver is to use the profile of logged-in Google users. However, it doesn't work if the profile is already in use from another instance of Chrome.
Anyone know of a way to detect if the profile of the currently logged-in user is in use? Then the utility can just skip adding that option into the list of arguments when we launch a browser.
I know there's a workaround for an individual computer, but as not everyone in the company will know how to set that up, it's okay if the instance doesn't automatically load the Google profile.

Add suggestion URL for custom search engine in chrome

I have a local search engine backed by a elasticsearch and a thin nodejs API for search. I want to be able to search those documents from Google Chrome (builds available from Google, not Chromium) directly. In this use case, I will use chrome ONLY with this search engine, so I don't want to use OmniBox keyword search API. I want the same behavior as I get while choosing the default search engine in chrome. Which is
Start typing in the OmniBox and it shows a list of suggestions.
Hit enter and it takes to the search results page
I got the #2 working by adding a new search engine under settings and providing the search api's url. I can't get #1 working.
The two urls exposed by my server are:
http://localhost:3000/complete?query=my (this returns a list of search suggestions which I want to show while typing in OmniBox).
http://localhost:3000/results?query=my+sample+query (this returns the actual search results as a web page, this is working)
Things that I have tried:
Added search engine using window.externals.AddSearchProvider with OpenSearchDescription.xml link. The XML has suggestions url as well.
Tried writing a background extension with OmniBox but it does not allow me to search without using a keyword
I searched through Chromium and found this JSON file
https://code.google.com/p/chromium/codesearch#chromium/src/components/search_engines/prepopulated_engines.json&q=prepopulated&sq=package:chromium&l=1
But I don't know how can I use it (or if its even possible to do this in official builds of Chrome).
I finally found the solution.
The opensearch.xml document reference can be used as a link in the head section of the HTML page. It contains two URL schemes, one for search results and other for suggestions.
The details can be found here:
Opensearch Document Specs.
As soon as I updated my index.html and opened the page in Chrome, Chrome automatically added a new search engine. It didn't show that there is a suggestions URL under Settings > Manage search engines.
Next, I chose my engine as the default search engine by clicking on Make Default and done! Now I can see all the search suggestions in the omnibox without using a keyword.
There is a Setting Overrides mechanism for Chrome Extensions, which is not widely known, which can achieve what you want, but:
At least according to the docs, it only works on Windows and Mac.
You won't be able to publish the extension unless you can verify the site in Webmaster Tools. Otherwise, you are stuck with unpacked installs.

Can one configure Chrome to offer opening downloads in suitable applications?

I recently made Google Chrome my default browser (mainly due to its bookmark and preferences syncing capabilities across multiple systems).
One thing I find increasingly annoying with it though is, that Chrome does not allow to directly open a downloaded file in an appropriate application!
In IE I was us to, that, when I clicked onto a link pointing to some document, e.g. a spreadsheet, to being asked, whether I wanted to save this document to a local file or to directly open it (in Excel in this example). This worked with all kinds of registered applications but also other formats, e.g. email addresses (mailto:-links) or Calendar entries (.ics-files) which directly opened Outlook's new email dialog with the email-address already filled int or created a new calendar entry from the .ics file, resp.
In Chrome one can only save such docs to a local file and then needs to locate that and has to open it manually. I find this always most cumbersome! Is there some plugin that allows to bring back the convenience I was used to?
And to spare me the usual comments on such feature requests right away: Yes, I am aware, that this is a potential security issue, if one opens docs from dubious sources, etc. I know, that one needs to understand what one is doing in such situations, but I think I do!
Click the little arrow beside the file, which is being downloaded and choose Always open files of this type. That will make it open automatically in the program the file type has been associated with in Windows after it finishes downloading.

right-click-then-open-with works but simple left-click does not

At some point in the last couple of days a bug seems to have materialised in my app's Google Drive integration, despite me not having changed anything, and usage remaining fairly constant.
When you left click one of the app's documents in Drive a new about:blank tab opens showing the app's icon and the text "Sorry, an error occurred while opening this file. Please try again. [XXXXX]" where [XXXXX] is a short string that seems to be different every time. The create new works fine, and if you use the right-click menu and open with it also works fine.
All of this makes me think that there is a bug in the latest javascript update to Google Drive's main interface.
In terms of debugging, in the apiconsole the app has...
The initiate oauth2 option unchecked
The allow multiple files option unchecked
Mobile browser support checked
24 mime-types, 61 primary extensions, and 1 secondary extension registered
If it is a bug as Claudio has mentioned, I believe Google Drive SDK documentation needs to be updated too, since 'open' action is described only for "Open With" option:
https://developers.google.com/drive/integrate-open
I'm wondering how to trigger the proper action when registred mime-type can be managed by more than one installed application? Is there a way to set the default open action - or the application which created it will be used as the default? What's happen if you reach the application web by typing the url (not from UI Drive UI create action) and save the content on Drive, since you may be already authorized to do it?