From 5f0bdc90027b3369582c9f724ed18f9c469d1c50 Mon Sep 17 00:00:00 2001 From: KOSASIH Date: Sun, 25 Aug 2024 06:39:08 +0700 Subject: [PATCH] Create did.js --- app/decentralized_identity/did.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 app/decentralized_identity/did.js diff --git a/app/decentralized_identity/did.js b/app/decentralized_identity/did.js new file mode 100644 index 0000000..45d745b --- /dev/null +++ b/app/decentralized_identity/did.js @@ -0,0 +1,15 @@ +import { uPort } from 'uport-react-native'; + +const did = { + createIdentity: () => { + const identity = uPort.createIdentity(); + return identity; + }, + + authenticate: (identity) => { + const authentication = uPort.authenticate(identity); + return authentication; + }, +}; + +export default did;