1
0
mirror of https://github.com/oceanprotocol-archive/squid-js.git synced 2024-02-02 15:31:51 +01:00

latest adoption

This commit is contained in:
Sebastian Gerske 2018-12-05 12:40:38 +01:00
parent 8f1e7b016e
commit d4b6366a4a
3 changed files with 4 additions and 9 deletions

View File

@ -22,7 +22,7 @@ export default class DDO {
public constructor(ddo?: { public constructor(ddo?: {
id?: string, id?: string,
publicKey?: any[], publicKey?: PublicKey[],
authentication?: Authentication[], authentication?: Authentication[],
service?: Service[], service?: Service[],
}) { }) {

View File

@ -1,6 +1,6 @@
export default class PublicKey { export default class PublicKey {
public id: string = "did:op:123456789abcdefghi#keys-1" public id: string = "did:op:123456789abcdefghi#keys-1"
public type: string = "RsaVerificationKey2018" public type: string = "Ed25519VerificationKey2018"
public owner: string = "did:op:123456789abcdefghi" public owner: string = "did:op:123456789abcdefghi"
public publicKeyPem?: string = "-----BEGIN PUBLIC KEY...END PUBLIC KEY-----\r\n" public publicKeyPem?: string = "-----BEGIN PUBLIC KEY...END PUBLIC KEY-----\r\n"
public publicKeyBase58?: string = "H3C2AVvLMv6gmMNam3uVAjZpfkcJCwDwnZn6z3wXmqPV" public publicKeyBase58?: string = "H3C2AVvLMv6gmMNam3uVAjZpfkcJCwDwnZn6z3wXmqPV"

View File

@ -9,6 +9,7 @@ import DDO from "../ddo/DDO"
import Event from "../ddo/Event" import Event from "../ddo/Event"
import EventHandlers from "../ddo/EventHandlers" import EventHandlers from "../ddo/EventHandlers"
import MetaData from "../ddo/MetaData" import MetaData from "../ddo/MetaData"
import PublicKey from "../ddo/PublicKey"
import Service from "../ddo/Service" import Service from "../ddo/Service"
import ContractEvent from "../keeper/Event" import ContractEvent from "../keeper/Event"
import Keeper from "../keeper/Keeper" import Keeper from "../keeper/Keeper"
@ -90,16 +91,10 @@ export default class Ocean {
publicKey: [ publicKey: [
{ {
id: did + "#keys-1", id: did + "#keys-1",
},
{
type: "Ed25519VerificationKey2018", type: "Ed25519VerificationKey2018",
},
{
owner: did, owner: did,
},
{
publicKeyBase58: await publisher.getPublicKey(), publicKeyBase58: await publisher.getPublicKey(),
}, } as PublicKey,
], ],
service: [ service: [
{ {