I need install chrome extension as a manual way. So I follow this page https://developer.chrome.com/extensions/external_extensions. I install chrome extension with registry. Everything was fine. But the problem is: that extension cannot "remember anything". Each time I close and open chrome, it was installed again (extension show a welcome page) and everything it save from last session has gone. That problem does not exists if I install it as a normal way. So there are anyway to solve it?
Navigate to "chrome://extensions/" in the url bar...
Click "Developer mode" in the top right hand corner.
Click "Pack extension..."
In the "Extension root directory" field, choose the folder that contains all your extension files.
Leave the "Private key file" blank...
Click OK
Your extension will now be packed into a .crx file wherever your parent extension directory was on your computer... there will also be a .pem file, which is irrelevant really, it just holds your private key in case you won't to update this same extension, in which case you would pack the extension with the private key file...
Open the .crx in chrome... It will give you a message saying extensions and themes may harm your computer... click OK, this message only shows up because the extension has not been tested by google in the extension gallery... Your extension will install and will remember all your data
Related
My problem is the same as this question: How to change chrome packaged app id Or Why do we need key field in the manifest.json?
Our extension isn't going to be published to the web store, I tried creating the crx file using Pack Extension in development mode, and then I uploaded the crx file to https://robwu.nl/crxviewer/ but it said:
Unexpected crx format version number
I tried unzipping the crx file to see the key field in manifest.json but it's not set at all.
I can't find my extension in my user data directory, my extension uses native messaging and I need the ID to be constant on all client devices for allowed_origins to work in the native host manifest.
So how to get the key value for our manifest?
You are getting that error because https://robwu.nl/crxviewer/ might be outdated. Install CRX viewer from the web store instead. After installing, use it on any extension. You will see something like this:
Click Open on the upper-right corner. You will see a page that looks similar to https://robwu.nl/crxviewer/. Now, click Choose File button and select your crx file. Open chrome's console (press F12 and click Console if it isn't selected by default) and you will see the key value for your manifest. Copy that and paste it into your extension's source manifest file.
I am trying to modify a small thing from an extension. All I basically need to edit, is the selector they use. If their selector is $("#firstDiv") I need it to be $("#secondDiv"). It is really that simple.
I downloaded the CRX file, extracted it, made the edit, but when I go and install it in my browser, it asks me to authenticate with Google Authenticator. Just like it's supposed to do, as it uses oAuth 2. HOWEVER, once I log into my Google account, it will not "save" the login. Right after I log in and press Log In, the tab closes and launches the same login page again on another page.
Is it possible to change that somehow? I found a semi-workaround. If I install the extension, authenticate with Google, then go make my edit in the extension folder, it works perfectly. However, I cannot send it to someone else, because the manifest.json includes my authentication key (392 characters long).
How can I modify the extension to my needs? Is there something I need to know about Google OAuth?
EDIT: Okay, I cannot even download the .crx file directly from Google, unzip the file, then move the files into a new folder, and install that script. Exactly like it came from Google. Are their .crx files signed? Is it impossible to do this?
When you download the .crx file, extract it, edit it and install it, its extension id is changed from the original one(this is the reason you are getting login page again and again). Now, client id used in extension is valid for only the original extension id. Thats why when you install it from web store it works fine because it retains its original extension id.
Solution :
You must retain the original extension id to make it work. First download crx viewer(very helpful for extension developers)
After installing crx viewer, navigate to your extension from web store. You will notice a page action(icon at the end of url). Click it , then click view source. New tab will open, then press f12 and check the console, you will find a "key" value. Copy it. Now go to your extension page again and download the extension as zip(from crx). Extract it and open its manifest.json file and paste the "key" along with value.(This step is necessary to retain extension id). Now install the extension from chrome by enabling developer's mode and clicking load unpacked extension and selecting the extracted extension. It should work now
I have an extension that is hosted in Chrome wwebstore, I want to make an installer that installs it automatically through registry, however, I seems that this method does not work anymore, and if it works it wont be activated. Is there any other possible solution after the last chrome updates.
No matter which method you use for an installer, the extension will be initially disabled and user will be presented with a question whether he wants to enable your extension.
That said, this is still the correct method. Add a key to the registry, on next launch Chrome will download the extension and present a dialog to the user.
The only way to install an extension "no questions asked" (on Windows) is through domain policies.
i was wondering if it's possible for a user to install a Chrome extension through my website in any possible way instead via Google's marketplace.
Thanks!
According to the documentation from Google, users can install your extension via your website. The recommended way is for you to enable inline installation of your extension; otherwise, users will need to do the following:
Download the extension file from the website and save it to your computer.
Click the Chrome menu icon Chrome menu on the browser toolbar.
Select Tools > Extensions.
Locate the extension file on your computer and drag the file onto the Extensions page.
Review the list of permissions in the dialog that appears. If you would like to proceed, click Install.
When you install an extension to the Google Chrome browser from Chrome's website, the installation procedure pops up instantly, without warning. (Chrome's website)
When you install an extension from any other website, there is a warning message: "Extensions, apps, and themes can harm your computer. Are you sure you want to continue?"
My extension is trusted and displayed on Chrome's website, but is there a way to remove this scary warning from my website's download page ?
Thanks
I figured out myself there is no way to do this because chrome just checks if the extension install is launched from its own website.
For people wondering what I eventually did (if there will ever be) :
As soon as the user clicks on the install button, I hide the document with an 80% opaque layer and show a box pointing where to click to continue the installation.