Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
uport-transports
Advanced tools
[![Join the chat at](https://img.shields.io/badge/Riot-Join%20chat-green.svg)](https://chat.uport.me/#/login) [![npm](https://img.shields.io/npm/dt/uport-transports.svg)](https://www.npmjs.com/package/uport-transports) [![npm](https://img.shields.io/npm/v
Introduction | Quick Start | Modules | Development Guide
:bangbang: :warning: Transport modules rely on a spec change that is yet to be released in the uPort mobile app. Until the new mobile app is released, integrating the transport modules is not fully supported. Once it is fully supported, we will remove this message.
For more information about uPort visit both uport.me and the developer docs site for more information on our platform and other libraries.
uport-transports
is a loosely coupled collection of functions and modules to use for building on and interacting with the uPort platform. If you are looking for quick start integration you will likely be better served by using both uport-connect and uport-credentials. But if you are looking for a deeper understanding or integration, customizing functionality for the other libraries or building your own libraries on the uPort platform, then you may want to use what is provided here.
For any questions or library support reach out to the uPort team on Riot or create a Github issue.
Install through npm:
npm install uport-transports
Import specific modules:
import { transport, message, crypto } from 'uport-transports'
Transports deal with sending messages to and from uPort clients, and generally setting up communication channels. Most often this involves sending messages to and from the uPort mobile app. At this time there are three primary transports:
QR Codes: Messages are sent in a QR code to the mobile app client. You can use our default modal and flow here or configure your own QR codes. You can use our messaging server Chasqui
to receive responses our have response returned to your own server.
URL Passing: Messages are sent in a QR code to the mobile app client. You can use our default modal and flow here or configure your own QR codes. You can use our messaging server Chasqui
to receive responses our have response returned to your own server.
Push Notifications: Messages are sent in a QR code to the mobile app client. You can use our default modal and flow here or configure your own QR codes. You can use our messaging server Chasqui
to receive responses our have response returned to your own server.
Beside the primary transports provided there is a number of smaller composable functions available to build your own transports for different needs. As we (and the community) build more transports for differing communication channels and differing uPort clients we will add them here.
Only contains util functions at this time that help with adding params to request URIs. May contain other functions related to creating and parsing messages on our platform.
Only contains encryptMessage()
at this time, which is used for push notifications. May include a collection of other commonly used crypto functions in the future.
Transport
uport.transport.qr.send()
uport.transport.qr.chasquiSend()
uport.transport.qr.open()
uport.transport.qr.close()
uport.transport.qr.getImageDataURI()
uport.transport.qr.modalTemplate()
uport.transport.url.send()
uport.transport.url.getResponse()
uport.transport.url.listenResponse()
uport.transport.url.onResponse()
uport.transport.push.send()
uport.transport.messageServer.URIHandlerSend()
uport.transport.messageServer.poll()
uport.transport.messageServer.clearResponse()
uport.transport.poll()
Message
uport.message.util.paramsToUrlFragment()
uport.messasge.util.paramsToQueryString()
Crypto
uport.crypto.encryptMessage()
uport.crypto.randomString()
Provider
uport.provider()
Network
uport.network.config.network()
uport.network.config.networkSet()
uport.network.config.networkToNetworkSet()
uport.network.default.networks
uport.network.default.NETWORK
Download this repo or your fork, then run npm install
.
All builds are created from files in /src
To transpile to ES5. All files are output to /lib
. The entry of our npm package is /lib/index.js
$ npm run build:es5
To generate a bundle/distributable. We use webpack for our builds. The output dist is /dist/uport-transports.js
and source map /dist/uport-transports.map.js
$ npm run build:dist
We write our tests using mocha, chai and sinon.
To run our tests:
$ npm run test
FAQs
Set up communication channels between your app and a uPort client to handle requests and responses
The npm package uport-transports receives a total of 16 weekly downloads. As such, uport-transports popularity was classified as not popular.
We found that uport-transports demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 6 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
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.