| | |
| | | "replace: ds-cfg-allow-ldap-v2", |
| | | "ds-cfg-allow-ldap-v2: false"); |
| | | |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password", LDAPResultCode.PROTOCOL_ERROR); |
| | | } |
| | |
| | | @Test(expectedExceptions = EOFException.class) |
| | | public void testRejectExtendedRequest() throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | conn.writeMessage(new ExtendedRequestProtocolOp(OID_START_TLS_REQUEST)); |
| | |
| | | public void testRejectAddControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |
| | |
| | | public void testRejectBindControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password", |
| | | LDAPResultCode.PROTOCOL_ERROR, new LDAPControl(OID_MANAGE_DSAIT_CONTROL, true)); |
| | |
| | | public void testRejectCompareControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |
| | |
| | | public void testRejectDeleteControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |
| | |
| | | public void testRejectModifyControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |
| | |
| | | public void testRejectModifyDNControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |
| | |
| | | public void testRejectSearchControls() |
| | | throws Exception |
| | | { |
| | | try (RemoteConnection conn = new RemoteConnection("localhost", TestCaseUtils.getServerLdapPort())) |
| | | try (RemoteConnection conn = new RemoteConnection("127.0.0.1", TestCaseUtils.getServerLdapPort())) |
| | | { |
| | | bindLdapV2(conn, "cn=Directory Manager", "password"); |
| | | |