From 39a6af7be859561bc78afac0ef5158b7efd47429 Mon Sep 17 00:00:00 2001 From: Tor Brede Vekterli Date: Tue, 14 Feb 2023 13:35:56 +0100 Subject: Correct checks for redirected I/O during interactive token resealing --- .../src/main/java/com/yahoo/vespa/security/tool/crypto/DecryptTool.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vespaclient-java/src/main/java/com/yahoo') diff --git a/vespaclient-java/src/main/java/com/yahoo/vespa/security/tool/crypto/DecryptTool.java b/vespaclient-java/src/main/java/com/yahoo/vespa/security/tool/crypto/DecryptTool.java index 4b3608fc3f7..8c85f7be49d 100644 --- a/vespaclient-java/src/main/java/com/yahoo/vespa/security/tool/crypto/DecryptTool.java +++ b/vespaclient-java/src/main/java/com/yahoo/vespa/security/tool/crypto/DecryptTool.java @@ -146,7 +146,7 @@ public class DecryptTool implements Tool { private static SecretSharedKey secretFromInteractiveResealing(ToolInvocation invocation, String inputArg, String outputArg, SealedSharedKey sealedSharedKey) throws IOException { - if (!CliUtils.useStdIo(outputArg) || !CliUtils.useStdIo(inputArg)) { + if (CliUtils.useStdIo(outputArg) || CliUtils.useStdIo(inputArg)) { throw new IllegalArgumentException("Interactive token resealing not available with redirected I/O"); } var session = SharedKeyResealingSession.newEphemeralSession(); -- cgit v1.2.3