Chrome扩展程序-我可以将扩展程序共享为crx文件以供他人使用吗? [英] Chrome extension - Can I share my extension as crx file for using someone?

查看:99
本文介绍了Chrome扩展程序-我可以将扩展程序共享为crx文件以供他人使用吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Google网上应用店中发布了扩展程序,并将其成功安装到chrome中.

I publish my extension in google web store and install it successfully in my chrome.

所以我在此目录中找到扩展的文件:

So I find extension's files in this directory:

C:\Users\User_Name\AppData\Local\Google\Chrome\User Data\Default\Extensions.

我将扩展程序用于chrome中的本机消息传递.

I use my extension for native messaging in chrome.

如何获取.crx文件以将扩展名发布给没有Internet连接的其他人?

How do I get .crx file for publish my extension for other people without internet connections?

或与Firefox * .xpi文件完全一样.

Or exactly like firefox *.xpi files.

也:

如果我在上面的DIR中打包扩展名的文件以压缩并重命名为crx文件,然后下拉至chrome,则会发生此错误:

If I pack extension's files in above DIR to zip and rename to crx file, and drop down to chrome this error occurs:

包裹无效:CRX_HEADER_INVALID.

Package is invalid: CRX_HEADER_INVALID.

推荐答案

包装

扩展名和主题用作.crx文件.通过Chrome开发人员信息中心上传时,信息中心会自动创建.crx文件.如果在个人服务器上发布了.crx文件,则需要在本地创建该文件或从Chrome网上应用店下载该文件.

Extensions and themes are served as .crx files. When uploading through the Chrome Developer Dashboard , the dashboard creates the .crx file automatically. If published on a personal server, the .crx file will need to be created locally or downloaded from the Chrome Web Store.

从Chrome网上应用店下载.crx

如果扩展程序托管在Chrome网上应用店中,则可以从开发人员信息中心下载.crx文件.在您的列表"下找到扩展名,然后单击更多信息".在弹出窗口中,单击蓝色的main.crx链接进行下载.

If an extension is hosted on the Chrome Web Store, the .crx file can be downloaded from the Developer Dashboard. Locate the extension under "Your Listings" and click on "More info". In the popup window, click the blue main.crx link to download it.

下载的文件可以托管在个人服务器上.这是在本地托管扩展程序的最安全的方法,因为扩展程序的内容将由Chrome网上应用店进行签名.这有助于检测潜在的攻击和篡改.

The downloaded file can be hosted on a personal server. This is the most secure way to host an extension locally as the contents of the extension will be signed by the Chrome Web Store. This helps detect potential attacks and tampering.

在本地创建.crx

扩展目录在扩展管理页面上转换为.crx文件.转到ominibox中的chrome://extensions/,或单击Chrome菜单,将鼠标悬停在更多工具"上,然后选择扩展程序".

Extension directories are converted to .crx files at the Extensions Management Page. Navigate to chrome://extensions/ in the ominibox, or click on the Chrome menu, hover over "More Tools" then select "Extensions".

在扩展管理"页面上,通过单击开发人员模式"旁边的切换开关来启用开发人员模式".然后选择PACK EXTENSION按钮.

On the Extensions Management Page, enable Developer Mode by clicking the toggle switch next to Developer mode. Then select the PACK EXTENSION button.

在扩展程序根目录字段中指定扩展程序文件夹的路径,然后单击PACK EXTENSION按钮.忽略首次安装包的私钥"字段.

Specify the path to the extension’s folder in the Extension root directory field then click the PACK EXTENSION button. Ignore the Private key field for a first-time package.

Chrome将创建两个文件,一个.crx文件和一个.pem文件,其中包含扩展程序的私钥.

Chrome will create two files, a .crx file and a .pem file, which contains the extension’s private key.

不要丢失私钥!将.pem文件保存在秘密安全的地方;需要更新扩展名.

Do not lose the private key! Keep the .pem file in a secret and secure place; it will be needed to update the extension.

了解详情

这篇关于Chrome扩展程序-我可以将扩展程序共享为crx文件以供他人使用吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆