Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

uport

Package Overview
Dependencies
Maintainers
1
Versions
63
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

uport - npm Package Compare versions

Comparing version 0.4.1 to 0.4.2

6

lib/Credentials.js

@@ -69,2 +69,5 @@ 'use strict';

}
if (params.network_id) {
payload.net = params.network_id;
}
return (0, _JWT.createJWT)(this.settings, _extends({}, payload, { type: 'shareReq' }));

@@ -87,2 +90,5 @@ }

var credentials = _extends({}, profile, payload.own || {}, payload.capabilities && payload.capabilities.length === 1 ? { pushToken: payload.capabilities[0] } : {}, { address: payload.iss });
if (payload.nad) {
credentials.networkAddress = payload.nad;
}
if (payload.verified) {

@@ -89,0 +95,0 @@ return Promise.all(payload.verified.map(function (token) {

2

package.json
{
"name": "uport",
"version": "0.4.1",
"version": "0.4.2",
"description": "Library for interacting with uport profiles and attestations",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -84,2 +84,10 @@ # uport-js

If you need to know the users address on a specific ethereum network, specify it's `network_id` (currently defaults to ropsten `0x3`). In this case be aware that the `address` returned will be the address on the public network (currently ropsten) for the users profile. The requested network address will be in the `networkAddress` field and will be MNID encoded.
```javascript
credentials.createRequest({network_id: '0x4'}).then(requestToken => {
// send requestToken to browser
})
```
In your front end use [uport-connect](https://github.com/uport-project/uport-connect) to present it to your user either as a QR code or as a uport-button depending on whether they are on a desktop or mobile browser.

@@ -86,0 +94,0 @@

@@ -35,2 +35,5 @@ import { createJWT, verifyJWT } from './JWT'

}
if (params.network_id) {
payload.net = params.network_id
}
return createJWT(this.settings, {...payload, type: 'shareReq'})

@@ -43,2 +46,5 @@ }

const credentials = {...profile, ...(payload.own || {}), ...(payload.capabilities && payload.capabilities.length === 1 ? {pushToken: payload.capabilities[0]} : {}), address: payload.iss}
if (payload.nad) {
credentials.networkAddress = payload.nad
}
if (payload.verified) {

@@ -45,0 +51,0 @@ return Promise.all(payload.verified.map(token => verifyJWT(this.settings, token))).then(verified => {

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc