8000 fix: Remove DidDocument as a param for DidSigner by vinuth-m · Pull Request #127 · affinidi/affinidi-ssi-dart · GitHub
[go: up one dir, main page]

Skip to content

fix: Remove DidDocument as a param for DidSigner - #127

Merged
vinuth-m merged 3 commits into
v2from
DidSignerSimplify
Jul 3, 2025
Merged

vinuth-m merged 3 commits into
v2from
DidSignerSimplify

Conversation

@vinuth-m
@vinuth-m vinuth-m commented Jul 2, 2025
Copy link
Copy Markdown
Contributor

This makes it simpler to use remote KeyPairs without having to fetch the publicKey to create the DidDocument to satisfy the interface, where the publicKey is not actually used by any of the existing signers.

Needs discussion: I have removed the get publicKey from DidSigner as well. Currently it hasn't been used anywhere, including tests and example code snippets. Are there scenarios where this getter would be helpful? cc: @cosminm-affnd @marco-a-affinidi @carlos-affinidi

Adding this change to v2 since it is a breaking change.

@vinuth-m
vinuth-m requested a review from a team as a code owner July 2, 2025 08:25
@github-actions
github-actions Bot commented Jul 2, 2025
Copy link
Copy Markdown

Coverage after merging DidSignerSimplify into v2 will be

78.05%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
lib/src
   types.dart82.35%100%100%82.35%102, 124, 179
   utility.dart100%100%100%100%
   digest_utils.dart100%100%100%100%
lib/src/credentials/jwt
   jwt_data_model_v1.dart97.56%100%100%97.56%57
   jwt_dm_v1_suite.dart86%100%100%86%109, 111, 36, 38, 56, 71, 73
lib/src/credentials/linked_data
   ld_base_suite.dart91.49%100%100%91.49%102, 104, 86, 88
   ld_dm_v1_suite.dart100%100%100%100%
   ld_dm_v2_suite.dart100%100%100%100%
lib/src/credentials/models/field_types
   issuer.dart100%100%100%100%
   credential_schema.dart100%100%100%100%
   credential_subject.dart72.97%100%100%72.97%38, 55, 57–58, 61, 64–65, 70–71, 94
   evidence.dart76.47%100%100%76.47%50–52, 54
   holder.dart92.31%100%100%92.31%90
   terms_of_use.dart75%100%100%75%46–48, 50
lib/src/credentials/models/field_types/credential_status
   v1.dart0%100%100%0%11–12, 124–126, 128–129, 13, 130, 134–135, 138, 14, 140–142, 145–146, 15, 51–57, 60–61, 64, 66–68, 71, 73–76, 78, 82–83, 85–86, 88–89
   v2.dart50%100%100%50%136, 138–140, 143–144, 59–60, 63, 65–67, 70, 72–75, 77, 81–82, 87–88
lib/src/credentials/models/field_types/refresh_service
   v1.dart76.47%100%100%76.47%46–48, 50
   v2.dart18.18%100%100%18.18%35–36, 38, 55–56, 61, 66–67, 69
lib/src/credentials/models/v1
   mutable_vc_data_model_v1.dart85%100%100%85%153–155, 203–204, 210–211, 217, 223
   vc_data_model_v1.dart85.86%100%100%85.86%159–161, 166, 168–169, 174–176, 181–183, 280–281
lib/src/credentials/models/v2
   mutable_vc_data_model_v2.dart43.33%100%100%43.33%145, 161–162, 164, 166, 168, 170, 172, 174–176, 179–180, 183, 185–187, 190, 192, 194, 196–198, 201, 203–205, 208, 210–211, 214, 216–217, 220
   vc_data_model_v2.dart83.70%100%100%83.70%138–140, 145, 147–148, 153–155, 160–162, 259, 265, 269
lib/src/credentials/parsers
   jwt_parser.dart88.89%100%100%88.89%51, 53
   ld_parser.dart85.71%100%100%85.71%26
   sdjwt_parser.dart70%100%100%70%40, 56, 58
lib/src/credentials/presentations/linked_data
   ld_vp_dm_v1_suite.dart100%100%100%100%
   ld_vp_dm_v2_suite.dart100%100%100%100%
lib/src/credentials/presentations/models
   vc_parse_present.dart88.89%100%100%88.89%27
lib/src/credentials/presentations/models/v1
   mutable_vp_data_model_v1.dart46.43%100%100%46.43%100–101, 104, 73, 76, 82–83, 85, 87–88, 90, 92, 94, 96–97
   vp_data_model_v1.dart82.69%100%100%82.69%79–81, 86, 88–89, 94–96
lib/src/credentials/presentations/models/v2
   vp_data_model_v2.dart82.76%100%100%82.76%100–101, 161, 84–86, 91, 93–94, 99
   mutable_vp_data_model_v2.dart45.45%100%100%45.45%100, 102–103, 106–107, 110, 112–113, 116, 78, 82, 88–89, 91, 93–94, 96, 98
lib/src/credentials/presentations/suites
   universal_presentation_parser.dart42.86%100%100%42.86%21–22, 24–25
   universal_presentation_verifier.dart0%100%100%0%27–28, 34, 36, 41–43, 45–48, 51–54, 57
   vp_suites.dart66.67%100%100%66.67%29–31
lib/src/credentials/presentations/verification
   vp_expiry_verifier.dart100%100%100%100%
   vp_integrity_verifier.dart100%100%100%100%
   vp_domain_challenge_verifier.dart75%100%100%75%36, 53–54, 62–63
lib/src/credentials/proof
   data_integrity_ecdsa_suite.dart92.31%100%100%92.31%42, 44–45
   data_integrity_eddsa_suite.dart92.31%100%100%92.31%42, 44–45
   ecdsa_secp256k1_signature2019_suite.dart98.33%100%100%98.33%110
   embedded_proof_suite.dart100%100%100%100%
   embedded_proof.dart70.59%100%100%70.59%107–108, 110, 114, 117, 148, 158–159, 165–167, 169, 183, 191, 197, 199, 76, 91, 96–97
   base_data_integrity_verifier.dart68.35%100%100%68.35%116–117, 122–123, 129–130, 141, 143, 145–146, 149, 152–153, 157–158, 209, 211–212, 241, 70–71, 77–78, 90–91
   base_secp256k1_verifier.dart82.43%100%100%82.43%113–114, 119–120, 129–130, 179, 181, 219, 67–68, 74–75
lib/src/credentials/sdjwt
   enveloped_vc_suite.dart80%100%100%80%102–104, 113, 115–116, 67, 69, 99
   sdjwt_dm_v2_suite.dart82.35%100%100%82.35%110, 112, 133–137, 192, 262, 265, 58, 60
   sdjwt_did_verifier.dart100%100%100%100%
lib/src/credentials/suites
   vc_suites.dart78.57%100%100%78.57%43–45
   universal_parser.dart100%100%100%100%
   universal_verifier.dart100%100%100%100%
lib/src/credentials/verification
   vc_expiry_verifier.dart100%100%100%100%
   vc_integrity_verifier.dart100%100%100%100%
lib/src/did
   did_signer.dart100%100%100%100%
   did_verifier.dart77.08%100%100%77.08%107–108, 113–114, 116–117, 136, 52, 63, 65–66
   public_key_utils.dart52.45%100%100%52.45%100–108, 110–112, 119–120, 123–125, 128–130, 132–133, 136–137, 139–140, 143–144, 146–147, 150–151, 153–154, 158–160, 165, 170–171, 173–174, 177–179, 222, 224, 23, 25, 290–292, 318, 320, 322, 324, 39–41, 61, 78–80, 95–99
   did_key.dart78.48%100%100%78.48%209, 211, 223, 228–231, 233, 236, 74, 79–80, 84, 86–87, 89–90
   did_peer.dart81.65%100%100%81.65%120–122,

@vinuth-m
vinuth-m merged commit 4f61600 into v2 Jul 3, 2025
@vinuth-m
vinuth-m deleted the DidSignerSimplify branch July 3, 2025 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

0