Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
@foreverholdings/convo-bootstrap
Advanced tools
This the bootstrap code to embed a `convo` into a page.
@foreverholdings/convo-bootstrap
This the bootstrap code to embed a convo
into a page.
It has a couple of responsibilities
<convo>
containing element
When the script runs, it turns
<convo>
<a href="https://convo.example.com/view/the-owls-are-not-what-they-seem">
View the experience
</a>
<script src="https://unpkg.com/@foreverholdings/convo-bootstrap/umd/cb.min.js"></script>
</convo>
into
<convo>
<iframe src="https://convo.example.com/iframe?id=the-owls-are-not-what-they-seem"></iframe>
</convo>
<convo>
containing elementWhen the user starts the conversation, the experience should move to either fullscreen or full viewport.
This will be achieved by using the postMessage
API. convo-bootstrap
will be responsible for setting styles on the <convo>
element, to achieve this and to use the Fullscren API when supported.
Some integrators will have concerns over including third party scripts in their pages.
The fundamental concern is that adding a third party script to the page will give the script full access to web storage (cookies, localStorage, IndexedDB, etc) and can steal user information or even impersonate users.
These are very valid concerns, which is why you never see third party scripts in e-commerce checkout, login pages for banks, etc.
To address these concerns, we will do a few things:
convo-bootstrap
to the public npm
registry
unpkg
, which is on Cloudflare's CDNconvo-bootstrap
on a web page (not with an open license), so integrators can review it. The annotations will explain exactly what each part of the script doesunpkg
via the ?meta
query parameterThis should remove any reservations integrators might have about including convo-bootstrap
script in their web pages.
See:
<convo>
<a href="https://convo.example.com/view/the-owls-are-not-what-they-seem">
View the experience
</a>
<script
<!-- load a specific version -->
src="https://unpkg.com/@foreverholdings/convo-bootstrap@16.7.0/umd/cb.min.js"
<!-- use Subresource Integrity -->
integrity="sha384-oqVuAfXRKap7fdgcCY5uykM6+R9GqQ8K/uxy9rx7HNQlGYl1kPzQho1wx4JwY8wC"
<!-- browser rejects failed hashes and send no credentials -->
crossorigin="anonymous"></script>
</convo>
When the request is not on the same origin the
crossorigin
attribute must be present to check the integrity of the file. Without acrossorigin
attribute, the browser will choose to 'fail-open' which means it will load the resource as if the integrity attribute was not set, effectively losing all the security SRI brings in the first place.crossorigin="anonymous"
ensures that no credentials are sent to the cross-origin site hosting the content. However, it will send an Origin HTTP header. If the server denies including the resource (by not setting the Access-Control-Allow-Origin HTTP header), the resource will not be used by the browser.
npm ci
npm start
open http://localhost:8080
FAQs
This the bootstrap code to embed a `convo` into a page.
The npm package @foreverholdings/convo-bootstrap receives a total of 0 weekly downloads. As such, @foreverholdings/convo-bootstrap popularity was classified as not popular.
We found that @foreverholdings/convo-bootstrap demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 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
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.