
Research
Malicious npm Packages Impersonate Flashbots SDKs, Targeting Ethereum Wallet Credentials
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
apollo-link-webextensions-messaging
Advanced tools
> Apollo link that, in a WebExtension, forwards GraphQL operations between processes
Apollo link that, in a WebExtension, forwards GraphQL operations between processes
npm i -S apollo-link-webextensions-messaging
reactive-graphql
and apollo-link-reactive-schema
Port
creation method: adaptable for cross-extension messaging or native messagingPort
(and esp. MessageSender
) in local GraphQL resolvers// ------------------
// in background page
import { createWebExtensionMessagingExecutorListener } from 'apollo-link-webextensions-messaging';
import { SchemaLink } from 'apollo-link-schema';
import schema from './path/to/your/schema';
// local schema execution
const link = new SchemaLink({
schema,
context: operation => ({
// `createWebExtensionMessagingExecutorListener` will
// add `port`, the `onConnect`'s `Port` as Operation's context
// we extract the `MessageSender` into GQL's context so that
// it can be used in resolvers
sender: operation.getContext().port.sender,
})
});
const listener = createWebExtensionMessagingExecutorListener({
link,
});
chrome.runtime.onConnect.addListener(listener);
// ----------------
// in content script
import { createWebExtensionsMessagingLink } from 'apollo-link-webextensions-messaging';
import { ApolloClient } from 'apollo-client';
import { InMemoryCache } from 'apollo-cache-inmemory';
const port = chrome.runtime.connect();
const client = new ApolloClient({
// can also be `createWebExtensionsMessagingLink((operation) => port)`
link: createWebExtensionsMessagingLink(port),
cache: new InMemoryCache(),
// from experience, if `queryDeduplication` is true,
// `client.watchQuery` unsubscription will not be
// properly passed down to the `link`
queryDeduplication: false,
});
client.query(MY_QUERY);
FAQs
> Apollo link that, in a WebExtension, forwards GraphQL operations between processes
The npm package apollo-link-webextensions-messaging receives a total of 0 weekly downloads. As such, apollo-link-webextensions-messaging popularity was classified as not popular.
We found that apollo-link-webextensions-messaging demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 7 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Four npm packages disguised as cryptographic tools steal developer credentials and send them to attacker-controlled Telegram infrastructure.
Security News
Ruby maintainers from Bundler and rbenv teams are building rv to bring Python uv's speed and unified tooling approach to Ruby development.
Security News
Following last week’s supply chain attack, Nx published findings on the GitHub Actions exploit and moved npm publishing to Trusted Publishers.