Skip to content

Commit

Permalink
Use the generic parser from rpki-commons 1.35
Browse files Browse the repository at this point in the history
  • Loading branch information
ties committed Oct 9, 2023
1 parent a501c3f commit 7aad1e1
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/main/java/net/ripe/rpki/rsyncit/rrdp/RrdpFetcher.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import com.google.common.annotations.VisibleForTesting;
import lombok.Getter;
import lombok.extern.slf4j.Slf4j;
import net.ripe.rpki.commons.crypto.cms.GenericRpkiSignedObjectParser;
import net.ripe.rpki.commons.crypto.cms.RpkiSignedObject;
import net.ripe.rpki.commons.crypto.cms.RpkiSignedObjectParser;
import net.ripe.rpki.commons.crypto.crl.X509Crl;
Expand Down Expand Up @@ -289,14 +290,10 @@ private Instant getTimestampForObject(final String objectUri, final byte[] decod
case Aspa:
case Roa:
case Gbr:
var signedObjectParser = new RpkiSignedObjectParser() {
public DateTime getPublicSigningTime() {
return getSigningTime();
}
};
var signedObjectParser = new GenericRpkiSignedObjectParser();

signedObjectParser.parse(ValidationResult.withLocation(objectUri), decoded);
yield Instant.ofEpochMilli(signedObjectParser.getPublicSigningTime().getMillis());
yield Instant.ofEpochMilli(signedObjectParser.getSigningTime().getMillis());
case Certificate:
X509ResourceCertificateParser x509CertificateParser = new X509ResourceCertificateParser();
x509CertificateParser.parse(ValidationResult.withLocation(objectUri), decoded);
Expand Down

0 comments on commit 7aad1e1

Please sign in to comment.