From 810bb023bcb7c867cc8e16fe353c2ea08a2ffed6 Mon Sep 17 00:00:00 2001 From: Xavi Aracil Date: Tue, 20 Dec 2022 13:07:45 +0100 Subject: [PATCH] Check against null values --- .../java/org/oneedtech/inspect/vc/probe/ExpirationProbe.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/inspector-vc/src/main/java/org/oneedtech/inspect/vc/probe/ExpirationProbe.java b/inspector-vc/src/main/java/org/oneedtech/inspect/vc/probe/ExpirationProbe.java index 01e6fb0..c616015 100644 --- a/inspector-vc/src/main/java/org/oneedtech/inspect/vc/probe/ExpirationProbe.java +++ b/inspector-vc/src/main/java/org/oneedtech/inspect/vc/probe/ExpirationProbe.java @@ -26,7 +26,7 @@ public class ExpirationProbe extends Probe { * and the expiration date is prior to the current date, the credential has expired. */ JsonNode node = crd.getJson().get(crd.getExpiresAtPropertyName()); - if(node != null) { + if(node != null && !node.isNull()) { try { ZonedDateTime expirationDate = ZonedDateTime.parse(node.textValue()); if (ZonedDateTime.now().isAfter(expirationDate)) {