mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

ian.packer
15.00.2016 20f97f6790078d616957061c44c522d9863308fb
OPENDJSDK-80 Decode base64 specified control values when parsing command line arguments

Add missing base64 decoding to match the documented behaviour/syntax
1 files modified
4 ■■■■ changed files
opendj-sdk/opendj-ldap-toolkit/src/main/java/com/forgerock/opendj/ldap/tools/Utils.java 4 ●●●● patch | view | raw | blame | history
opendj-sdk/opendj-ldap-toolkit/src/main/java/com/forgerock/opendj/ldap/tools/Utils.java
@@ -22,7 +22,7 @@
 *
 *
 *      Copyright 2006-2010 Sun Microsystems, Inc.
 *      Portions copyright 2014-2015 ForgeRock AS
 *      Portions copyright 2014-2016 ForgeRock AS
 */
package com.forgerock.opendj.ldap.tools;
@@ -141,7 +141,7 @@
        final String valString = remainder.substring(idx + 1, remainder.length());
        if (valString.charAt(0) == ':') {
            controlValue = ByteString.valueOfUtf8(valString.substring(1, valString.length()));
            controlValue = ByteString.valueOfBase64(valString.substring(1, valString.length()));
        } else if (valString.charAt(0) == '<') {
            // Read data from the file.
            final String filePath = valString.substring(1, valString.length());