sktston / aries-cloudagent-python

Hyperledger Aries Cloud Agent Python (ACA-Py) is a foundation for building decentralized identity applications and services running in non-mobile environments.

Home Page:https://wiki.hyperledger.org/display/aries

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

aries JSON-LD BBS+ review

baegjae opened this issue · comments

현재 issuing performance는 5 TPS 수즌으로 낮음
sktston/acapy-controller-java#5

bbs
https://github.com/animo/aries-cloudagent-python/tree/cwu-bbs-main

개선 방향 모색

진행상황

https://github.com/animo/aries-cloudagent-python/tree/cwu-bbs-main
을 동작시키고, 현재의 진척 상황을 파악 중

BBS+ library

libursa 의 경우, BBS+ 개발 진도가 느려,
MATTR global에서 libursa의 BBS+ 코드를 가져와 아래 코드를 만들고 자체 기술에 적용
https://github.com/mattrglobal/ffi-bbs-signatures

해당 코드는 aries-framework-go 진영에서 BBS+ 적용에 사용하었고, (3월)
aca-py 진영에서도 해당 코드를 기반으로 BBS+ 를 개발 중
(포크한 저장소에 python wrapper를 추가하였음 - https://github.com/animo/ffi-bbs-signatures)

JSON-LD rfc

https://github.com/hyperledger/aries-rfcs/tree/master/features/0593-json-ld-cred-attach

protocol 2.0

issue-credential, present-proof protocol 2.0 을 사용하여 JSON-LD BBS+ 를 개발 중임으로
#48
검토하였음.

설치 요약

https://github.com/animo/ffi-bbs-signatures 를 빌드하고 libbbs.dylib 를 시스템라이브러리에 저장
https://github.com/animo/aries-cloudagent-python/tree/cwu-bbs-main 를 클론하고 requirement.txt requirement.bbs.txt 라이브러리 설치

동작

계속 업데이트 중이지만,

현재까지는. jsonld 에서 사용가능한 암호화 기술 중 (https://w3c-ccg.github.io/ld-cryptosuite-registry/)
Ed25519 와 bbs의 bls12381g2 를 지원하고 있음.

create did

  • method: sov -> 기존 indy did
    key_type: ed25519 한정
  • method: key -> key 메소드 (https://w3c-ccg.github.io/did-method-key/) 특이점은 no ledger를 추구
    key_type: ed25519 or bls12381g2 두 방식 지원 (ed는 libindy를 사용하여 저장까지, bls는 libbbs 사용하여 keypair 생성 후 libindy의 wallet api 사용하여 저장)

issue credential v2

  • filter: indy -> 기존 indy VC
  • filter: ld_proof -> JSON-LD VC
    proofType: Ed25519Signature2018 or BbsBlsSignature2020
  • 정상 동작 확인 (아래는 done 시의 웹훅메시지)
    Ed25519Signature2018.txt
    BbsBlsSignature2020.txt
  • 내부 동작 부연 설명: (Faber) issue credential 시에 message (credential 내용 list)를 public key, secret key로 sign하여 signature를 포함하여 보내고, (Alice) store credential 시에 message를 public key로 signature를 verify 후에 libindy wallet API를 사용하여 저장

present proof v2

  • 개발 중

데모 추가하였음.
sktston/acapy-controller-java#7

signature 를 만드는 속도는 빠를 것으로 보이나, Json LD 항목을 web에서 가져오는데 소요시간이 상당한 것으로 보임. (추측)
(기존 indy 보다 현저히 느림 -> 추후 개선되면 indy 보다 빨라질 것으로 기대)

참고할만한 좋은 문서:
https://github.com/hyperledger/aries-cloudagent-python/blob/main/demo/AliceWantsAJsonCredential.md