webextension | Alpheios Browser Extensions

 by   alpheios-project JavaScript Version: incr-3.3.x.20210415330 License: ISC

kandi X-RAY | webextension Summary

kandi X-RAY | webextension Summary

webextension is a JavaScript library. webextension has no bugs, it has no vulnerabilities, it has a Permissive License and it has low support. You can download it from GitHub.

This repository contains the wrapper code for the Alpheios Reading Tools Browser extensions for Chrome, Firefox and Safari. The core functionality is provided by the alpheios-components library. The webextension wrapper code provides the implementation of the WebExtensions API (Chrome/FF) and App Extension API (Safari).
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              webextension has a low active ecosystem.
              It has 4 star(s) with 1 fork(s). There are 4 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 26 open issues and 154 have been closed. On average issues are closed in 41 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of webextension is incr-3.3.x.20210415330

            kandi-Quality Quality

              webextension has no bugs reported.

            kandi-Security Security

              webextension has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              webextension is licensed under the ISC License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              webextension releases are available to install and integrate.
              Installation instructions are available. Examples and code snippets are not available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of webextension
            Get all kandi verified functions for this library.

            webextension Key Features

            No Key Features are available at this moment for webextension.

            webextension Examples and Code Snippets

            No Code Snippets are available at this moment for webextension.

            Community Discussions

            QUESTION

            Firefox extension how to get extension storage value
            Asked 2021-May-31 at 07:30

            I created a temporary Firefox add-on which opens a new tab when an icon is clicked. I used the example provided in this link:

            https://github.com/mdn/webextensions-examples/tree/master/open-my-page-button

            This works fine but the new tab opens to a fixed URL. So added a preferences page using the code provided in this link:

            https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/Implement_a_settings_page

            Now I'm able to save a URL in the preference page of the extension and the saved URL can be verified in the Extension Storage, here is an image showing it:

            ...

            ANSWER

            Answered 2021-May-31 at 07:30

            Since you have the onGot(item) function working. You should give your preference_url a name to be traced from.

            As you can see, when you inspect the [ Extension Storage ]. The preference_url is stored in a key named as type.

            So, you should give it a name like preferred_URL or other name for easy tracking.

            Source https://stackoverflow.com/questions/67763573

            QUESTION

            How to remove all javascript from the page load except what is embedded in the html pupeteer
            Asked 2021-May-28 at 05:05

            Well guys, I have this script that adds the product to the cart, but I need it to work as quickly as possible, currently it’s working for about 19 seconds if you run this code, of course there are a number of factors that should be taken into account consideration, one of them is the response time of the website and everything ... Well, I took almost all the resources on this site to load faster

            https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/webRequest/ResourceType

            But I did not remove the script loading (javascript), but I want to remove all the javascript from the page except what is embedded in the html, that is, I want to prevent all references to javascript files except the javascript that is inserted in the html, and I would like to know if it is possible to disable html text loading, this is my code:

            ...

            ANSWER

            Answered 2021-May-28 at 05:05

            I was able to block all files with the extension .js after taking a deep look at Google, I used this code:

            Source https://stackoverflow.com/questions/67730914

            QUESTION

            Can a WebExtension override server IP addresses?
            Asked 2021-May-19 at 21:03

            Is it possible for a WebExtension to override the IP address of a server, or to modify/intercept DNS requests or override the DNS cache? I'm trying to code a WebExtension that provides browsers with the same functionality as cURL's --resolve.

            Specifically, to:

            • connect to a different IP than that listed in DNS
            • add entries for particular NXDOMAIN that the user wishes to resolve as if it existed
            • "resolve" particular entries offline
            • cache or pin DNS entries in a software-defined way in preparation for a known upcoming DNS poisoning attack

            In short: to simulate the effect of a hosts file, but without administrative privileges / messing with the rest of the system.

            ...

            ANSWER

            Answered 2021-May-19 at 21:03

            Yes, but (for now) not trivially.

            WebExtensions cannot rewrite these responses directly, but they can use the browser.proxy.onRequest API with ProxyInfo.proxyDNS to redirect DNS requests for affected domains through a SOCKS4 or SOCKS5 proxy which mangles the responses.

            You will, however, need a Native Host component (or a VPS, etc.) to actually run this proxy -- at least until Firefox adds support for WebExtension-run sockets (or provides a built-in non-socket-based proxying API).

            Source https://stackoverflow.com/questions/66697926

            QUESTION

            Run Chrome extension on every domain except one?
            Asked 2021-May-14 at 10:17

            I need a Chrome extension to run on every domain except for one. It runs everywhere with this:

            ...

            ANSWER

            Answered 2021-May-14 at 10:17

            To run everywhere except "google" domains use exclude_globs. In manifest.json:

            Source https://stackoverflow.com/questions/67518803

            QUESTION

            How to correctly make a copy of a textfield?
            Asked 2021-May-10 at 11:16

            My problem is that i can't get my textfields with document.getContent() and document.getContents(). So I tried to use XPath for selecting the objects, it works but i can't copy the object and add it again.

            For example:

            XPath Exception Comment //wps:txbx/w:txbxContent javax.xml.bind.MarshalException SAXException2, Missing @XmlRootElement-Annotation //wps:txbx/w:txbxContent/w:p/w:r javax.xml.transform.TransformerException unexpected Element, because it is on the wrong place

            I also tried to make a own object but this also don't worked for me, because it wasn't accepted as an JAXB Object.

            This is my code:

            ...

            ANSWER

            Answered 2021-May-03 at 07:12

            Probably a namespace issue... The txbx element is in xmlns:v="urn:schemas-microsoft-com:vml" So maybe just change it to: (I don't know how you declare namespaces in docx4j)

            Source https://stackoverflow.com/questions/67364630

            QUESTION

            AES GCM encrypt with web subtlecrypto and decrypt with flutter cryptography
            Asked 2021-Apr-05 at 15:05

            I'm trying to encrypt something in a webextension with SubtleCrypto and decrypt it in flutter with cryptography. I want to use a password to encrypt a message, send it to a app and decrypt it with the same password. For this I use AES GCM with pbkdf2

            I was able to find an encryption snippet on the Mozilla documentation page. However, I struggle decrypting it in flutter.

            I'm also having problems with terminology. SubtleCrypto uses iv, salt and tags while flutter cryptography uses nonce and mac.

            Javascript code:

            ...

            ANSWER

            Answered 2021-Apr-05 at 15:05

            The following issues exist in the Dart code:

            • The WebCryptoAPI code concatenates the GCM tag with the ciphertext in the order ciphertext | tag. In the Dart code, both parts have to be separated accordingly.
              Also, in the Dart code, the nonce/IV is not taken into account. A possible fix of decrypt() is:

            Source https://stackoverflow.com/questions/66952004

            QUESTION

            How to use windows.WindowState API (JavaScript)?
            Asked 2021-Mar-29 at 16:33

            I like to use the windows.WindowState API, but got the error "windows is not defined".

            ...

            ANSWER

            Answered 2021-Jan-30 at 17:47

            The windows API can only be used in extensions, and if you are using an extension, you need to request permission in your extension's manifest.json file.

            Then you would just use it like this:

            Source https://stackoverflow.com/questions/65971115

            QUESTION

            Getting certificate chain from rejected connections in firefox
            Asked 2021-Mar-23 at 11:22

            I am able to get the chains well if I use browser.webRequest.getSecurityInfo inside a browser.webRequest.onHeadersReceived listener during a regular https connection, but if the connection failed due to a security issue such as an expired certificate then onHeadersReceived never gets triggered.
            If I accept the bad certificate then onHeadersReceived does get triggered, but the security info does not contain the bad certificate.

            I tried looking at browser.webRequest.onErrorOccurred and browser.webRequest.onCompleted but had no luck in getting getSecurityInfo to work in those contexts

            I know the browser itself has this information because you can get it to display the certificate chain in the built in viewer (which can display arbitrary certificates in the format of url_encode(base64_encode(DER_certificate))

            Does any one know how can I get either nice certificate objects or at least the DER bytes (encoded or not, it doesn't matter) ?

            ...

            ANSWER

            Answered 2021-Mar-23 at 11:22

            If I accept the bad certificate then onHeadersReceived does get triggered, but the security info does not contain the bad certificate.

            This is a bug in Firefox.

            I tried looking at browser.webRequest.onErrorOccurred and browser.webRequest.onCompleted but had no luck in getting getSecurityInfo to work in those contexts

            Like the documentation says: getSecurityInfo only works in onHeadersReceived. There are two related bugs, 1499592 and 1474657, to make getSecurityInfo work with other listeners as well.

            Source https://stackoverflow.com/questions/66749208

            QUESTION

            WebExtension onBeforeReuest is not trigger for request from fetch API
            Asked 2021-Mar-01 at 08:49

            New to web extension development & I'm trying this example. However when I run this extension it does not trigger the listener.

            This is the manifest file.

            ...

            ANSWER

            Answered 2021-Mar-01 at 08:49

            Quoting MDN:

            To intercept resources loaded by a page (such as images, scripts, or stylesheets), the extension must have the host permission for the resource as well as for the main page requesting the resource.

            So, you also need to add 127.0.0.1 in manifest.json because it's not the same as localhost, which can actually point to a different IP.

            Source https://stackoverflow.com/questions/66417496

            QUESTION

            How can I get installed chrome extensions list with javascript
            Asked 2021-Feb-26 at 06:02

            I have a web site made by Python Django.

            And I want to check if a visitor's chrome browser's chrome extension is installed.

            I found some information, it looks possible with Javascript.

            https://www.python2.net/questions-993829.htm

            https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/management/getAll

            They say you can get all installed chrome extensions by writing it like this.

            chrome.management.getAll() or brower.management.getAll()

            But When I tried that "chrome.management" is not defined.

            Is it need to add library to use chrome.management?

            I read the API documents, But I didn't know How can I to do.

            Please teach me if you know about this. Thank you.

            ...

            ANSWER

            Answered 2021-Feb-26 at 06:02

            From the looks of chromes docs (https://developer.chrome.com/docs/extensions/reference/management/), it seems that chrome.management is only able to be used in chrome extensions with the management permission. There doesn't seem to be any real alternative for websites. (Although if you own the extension you might be able to create a hidden div with a specific id, then the website could detect that).

            If chrome did allow websites to see this it would also make fingerprinting much easier.

            Source https://stackoverflow.com/questions/66380739

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install webextension

            merge the master branch to the qa branch and push to GitHub
            GitHub Actions will execute the release.yml workflow to inject the build number, install the qa branch of alpheios-components, build the distribution files, and tag a pre-release in GitHub, with the dist files packaged as a release artifact.
            In the Safari build environment, pull the qa branch and extract the dist.zip from the Pre-release in GitHub to the local dist directory.
            Create the Safari Package as described in BUILD-SAFARI.md

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries

            Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Consider Popular JavaScript Libraries

            freeCodeCamp

            by freeCodeCamp

            vue

            by vuejs

            react

            by facebook

            bootstrap

            by twbs

            Try Top Libraries by alpheios-project

            arethusa

            by alpheios-projectJavaScript

            alpheios-core

            by alpheios-projectJavaScript

            safari-app-back

            by alpheios-projectSwift

            inflection-tables

            by alpheios-projectJavaScript

            alpheios5

            by alpheios-projectJavaScript