| | |
| | | * |
| | | * |
| | | * Copyright 2006-2008 Sun Microsystems, Inc. |
| | | * Portions Copyright 2015 ForgeRock AS |
| | | */ |
| | | package org.opends.server.tools; |
| | | |
| | |
| | | * |
| | | * @throws Exception If an unexpected problem occurs. |
| | | */ |
| | | @BeforeClass() |
| | | @BeforeClass |
| | | public void startServer() |
| | | throws Exception |
| | | { |
| | |
| | | /** |
| | | * Tests the EncodePassword tool with the --listSchemes argument. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testListSchemes() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --listSchemes and |
| | | * --authPasswordSyntax arguments. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testListAuthSchemes() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPassword and --storageScheme |
| | | * arguments. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearPassword() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPassword, --storageScheme, |
| | | * and --authPasswordSyntax arguments. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearAuthPassword() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPasswordFile and |
| | | * --storageScheme arguments. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearPasswordFromFile() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPasswordFile, --storageScheme, |
| | | * and --authPasswordSyntax arguments. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearAuthPasswordFromFile() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPassword and --storageScheme |
| | | * arguments using an invalid storage scheme. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearPasswordWithInvalidScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPassword, --storageScheme, |
| | | * and --authPasswordSyntax arguments using an invalid storage scheme. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearPasswordWithInvalidAuthScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool with the --clearPasswordFile and |
| | | * --storageScheme arguments using an a password file that doesn't exist. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearPasswordFromMissingFile() |
| | | { |
| | | String[] args = |
| | |
| | | * --storageScheme, and --authPasswordSyntax arguments using an a password |
| | | * file that doesn't exist. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testEncodeClearAuthPasswordFromMissingFile() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a valid matching encoded password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingPasswordsNoScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a valid matching encoded password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingPasswordsWithScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a valid matching encoded password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingEncodedPasswordsFromFile() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a valid matching auth password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingAuthPasswords() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a non-matching encoded password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingPasswordsNoScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a non-matching encoded password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingPasswordsWithScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a non-matching auth password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingAuthPasswords() |
| | | { |
| | | String[] args = |
| | |
| | | * with a valid matching encoded password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingPasswordsNoSchemeCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * with a valid matching encoded password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingPasswordsWithSchemeCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * with a valid matching auth password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareMatchingAuthPasswordsCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * with a non-matching encoded password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingPasswordsNoSchemeCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * with a non-matching encoded password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingPasswordsWithSchemeCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * with a non-matching auth password using the LDAP compare result as an |
| | | * exit code. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareNonMatchingAuthPasswordsCompareResult() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with a malformed encoded auth password. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareInvalidEncodedAuthPassword() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with an encoded password that uses an unknown scheme. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareEncodedPasswordWithUnknownScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with an encoded password that uses an unknown scheme. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareEncodedPasswordWithUnknownSeparateScheme() |
| | | { |
| | | String[] args = |
| | |
| | | * Tests the EncodePassword tool by performing a comparison of clear-text |
| | | * with an encoded auth password that uses an unknown scheme. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testCompareEncodedAuthPasswordWithUnknownScheme() |
| | | { |
| | | String[] args = |
| | |
| | | /** |
| | | * Tests the EncodePassword tool with the help options. |
| | | */ |
| | | @Test() |
| | | @Test |
| | | public void testHelp() |
| | | { |
| | | String[] args = { "--help" }; |