Skip to content

Commit

Permalink
removed unneeded var
Browse files Browse the repository at this point in the history
  • Loading branch information
paullatzelsperger committed Apr 20, 2024
1 parent da4bf3f commit bb1152b
Showing 1 changed file with 0 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,11 @@
import com.apicatalog.ld.signature.key.VerificationKey;
import com.apicatalog.vc.Presentation;
import com.apicatalog.vc.VcVocab;
import com.apicatalog.vc.Verifiable;
import com.apicatalog.vc.method.resolver.HttpMethodResolver;
import com.apicatalog.vc.method.resolver.MethodResolver;
import com.apicatalog.vc.proof.EmbeddedProof;
import com.apicatalog.vc.proof.Proof;
import com.apicatalog.vc.suite.SignatureSuite;
import com.apicatalog.vc.verifier.Verifier;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import jakarta.json.JsonObject;
Expand All @@ -43,7 +41,6 @@
import org.eclipse.edc.iam.identitytrust.spi.verification.SignatureSuiteRegistry;
import org.eclipse.edc.iam.identitytrust.spi.verification.VerifierContext;
import org.eclipse.edc.jsonld.spi.JsonLd;
import org.eclipse.edc.security.signature.jws2020.Jws2020SignatureSuite;
import org.eclipse.edc.spi.result.Result;
import org.eclipse.edc.util.uri.UriUtils;

Expand Down Expand Up @@ -121,14 +118,6 @@ public URI getBase() {
return base;
}

private Verifiable getVerify(JsonObject jo) {
try {
return Verifier.with(new Jws2020SignatureSuite(jsonLdMapper)).loader(loader).verify(jo);
} catch (VerificationError | DocumentError e) {
throw new RuntimeException(e);
}
}

private VerificationMethod resolveMethod(URI id, Proof proof, DocumentLoader loader) throws DocumentError {

if (id == null) {
Expand Down Expand Up @@ -224,8 +213,6 @@ private Result<Void> verifyProofs(JsonObject expanded, JsonStructure context) th
return failure("%s: %s".formatted(ErrorType.Invalid, VcVocab.PROOF));
}

var proofObject = expandedProof.asJsonObject();

var proofTypes = LdType.strings(expandedProof);

if (proofTypes == null || proofTypes.isEmpty()) {
Expand Down

0 comments on commit bb1152b

Please sign in to comment.