- 浏览: 190186 次
- 性别:
文章分类
最新评论
-
路人甲wxf:
.net可以在不使用证书的情况下修改密码,java做不到吗?
添加用户、修改ad密码 -
zxsosozhuzhu:
你好,我也遇到这个问题了,但是按照你的方法还是附件中文还是乱码 ...
java mail 纯文本附件乱码的解决方案 -
balaschen:
can4you 写道 请教问题:你好,请教一个问题,我现在要模 ...
spring2.0事务配置实验 -
can4you:
/**
* Created: 2007-2-1
* ...
FreeMarker解析字符串模板 -
can4you:
请教问题:你好,请教一个问题,我现在要模拟两个事务同时更新一 ...
spring2.0事务配置实验
java 代码
- /**
- *
- */
- package ldap;
- import java.util.Properties;
- import javax.naming.*;
- import javax.naming.ldap.*;
- import javax.naming.directory.*;
- /**
- * @author Keven Chen
- * @version $Revision 1.0 $
- *
- */
- public class AddAdUser {
- private static final String SUN_JNDI_PROVIDER = "com.sun.jndi.ldap.LdapCtxFactory";
- public static void main(String[] args) throws Exception {
- String keystore = "F:\\jdk1.5.0_08\\jre\\lib\\security\\cacerts";
- System.setProperty("javax.net.ssl.trustStore", keystore);
- Properties env = new Properties();
- env.put(Context.INITIAL_CONTEXT_FACTORY, SUN_JNDI_PROVIDER);// java.naming.factory.initial
- env.put(Context.PROVIDER_URL, "ldap://192.168.1.32:636");// java.naming.provider.url
- env.put(Context.SECURITY_AUTHENTICATION, "simple");// java.naming.security.authentication
- env.put(Context.SECURITY_PRINCIPAL,
- "cn=Administrator,cn=Users,dc=comwave,dc=com");// java.naming.security.principal
- env.put(Context.SECURITY_CREDENTIALS, "password");// java.naming.security.credentials
- env.put(Context.SECURITY_PROTOCOL, "ssl");
- String userName = "CN=test,CN=Users,DC=comwave,DC=com";
- String groupName = "CN=Domain Admins,CN=Users,DC=comwave,DC=com";
- LdapContext ctx = new InitialLdapContext(env, null);
- // Create attributes to be associated with the new user
- Attributes attrs = new BasicAttributes(true);
- // These are the mandatory attributes for a user object
- // Note that Win2K3 will automagically create a random
- // samAccountName if it is not present. (Win2K does not)
- attrs.put("objectClass", "user");
- attrs.put("sAMAccountName", "test");
- attrs.put("cn", "test");
- // These are some optional (but useful) attributes
- attrs.put("sn", "test");
- attrs.put("displayName", "test");
- attrs.put("description", "测试");
- attrs.put("userPrincipalName", "test@comwave.com");
- attrs.put("mail", "test@comwave.com");
- attrs.put("telephoneNumber", "1234568999");
- // some useful constants from lmaccess.h
- int UF_ACCOUNTDISABLE = 0x0002;
- int UF_PASSWD_NOTREQD = 0x0020;
- int UF_PASSWD_CANT_CHANGE = 0x0040;
- int UF_NORMAL_ACCOUNT = 0x0200;
- int UF_DONT_EXPIRE_PASSWD = 0x10000;
- int UF_PASSWORD_EXPIRED = 0x800000;
- // Note that you need to create the user object before you can
- // set the password. Therefore as the user is created with no
- // password, user AccountControl must be set to the following
- // otherwise the Win2K3 password filter will return error 53
- // unwilling to perform.
- attrs.put("userAccountControl", Integer.toString(UF_NORMAL_ACCOUNT
- + UF_PASSWD_NOTREQD + UF_PASSWORD_EXPIRED + UF_ACCOUNTDISABLE));
- // Create the context
- Context result = ctx.createSubcontext(userName, attrs);
- System.out.println("Created disabled account for: " + userName);
- ModificationItem[] mods = new ModificationItem[2];
- // Replace the "unicdodePwd" attribute with a new value
- // Password must be both Unicode and a quoted string
- String newQuotedPassword = "\"Password2000\"";
- byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
- mods[0] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE,
- new BasicAttribute("unicodePwd", newUnicodePassword));
- mods[1] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE,
- new BasicAttribute("userAccountControl", Integer
- .toString(UF_NORMAL_ACCOUNT + UF_PASSWORD_EXPIRED)));
- // Perform the update
- ctx.modifyAttributes(userName, mods);
- System.out.println("Set password & updated userccountControl");
- // now add the user to a group.
- try {
- ModificationItem member[] = new ModificationItem[1];
- member[0] = new ModificationItem(DirContext.ADD_ATTRIBUTE,
- new BasicAttribute("member", userName));
- ctx.modifyAttributes(groupName, member);
- System.out.println("Added user to group: " + groupName);
- } catch (NamingException e) {
- System.err.println("Problem adding user to group: " + e);
- }
- // Could have put tls.close() prior to the group modification
- // but it seems to screw up the connection or context ?
- ctx.close();
- System.out.println("Successfully created User: " + userName);
- }
- }
java 代码
- /**
- *
- */
- package ldap;
- import java.io.IOException;
- import java.io.UnsupportedEncodingException;
- import java.util.Hashtable;
- import javax.naming.Context;
- import javax.naming.NamingException;
- import javax.naming.directory.BasicAttribute;
- import javax.naming.directory.DirContext;
- import javax.naming.directory.ModificationItem;
- import javax.naming.ldap.InitialLdapContext;
- import javax.naming.ldap.LdapContext;
- import javax.naming.ldap.StartTlsRequest;
- import javax.naming.ldap.StartTlsResponse;
- /**
- * @author Keven Chen
- * @version $Revision 1.0 $
- *
- */
- public class UpdatePasswordTLS {
- public static void main (String[] args)
- {
- Hashtable env = new Hashtable();
- String adminName = "CN=Administrator,CN=Users,DC=comwave,DC=com";
- String adminPassword = "aadsasdfasd";
- String userName = "CN=keven,CN=Users,DC=comwave,DC=com";
- String newPassword = "aaaaaaaa";
- String keystore = "F:\\jdk1.5.0_08\\jre\\lib\\security\\cacerts";
- System.setProperty("javax.net.ssl.trustStore",keystore);
- //Access the keystore, this is where the Root CA public key cert was installed
- //Could also do this via command line java -Djavax.net.ssl.trustStore....
- //String keystore = "/usr/java/jdk1.5.0_01/jre/lib/security/cacerts";
- //System.setProperty("javax.net.ssl.trustStore",keystore);
- env.put(Context.INITIAL_CONTEXT_FACTORY,"com.sun.jndi.ldap.LdapCtxFactory");
- //set security credentials, note using simple cleartext authentication
- env.put(Context.SECURITY_AUTHENTICATION,"simple");
- env.put(Context.SECURITY_PRINCIPAL,adminName);
- env.put(Context.SECURITY_CREDENTIALS,adminPassword);
- env.put(Context.SECURITY_PROTOCOL,"ssl");
- //connect to my domain controller
- String ldapURL = "ldap://192.168.1.32:636";
- env.put(Context.PROVIDER_URL,ldapURL);
- try {
- // Create the initial directory context
- LdapContext ctx = new InitialLdapContext(env,null);
- //set password is a ldap modfy operation
- ModificationItem[] mods = new ModificationItem[1];
- //Replace the "unicdodePwd" attribute with a new value
- //Password must be both Unicode and a quoted string
- String newQuotedPassword = "\"" + newPassword + "\"";
- byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
- //注意:如果是当前用户自行修改密码,需要先删除oldpassword,然后在添加新的password
- /*
- ModificationItem[] mods = new ModificationItem[2];
- //Firstly delete the "unicdodePwd" attribute, using the old password
- //Then add the new password,Passwords must be both Unicode and a quoted string
- String oldQuotedPassword = "\"" + sOldPassword + "\"";
- byte[] oldUnicodePassword = oldQuotedPassword.getBytes("UTF-16LE");
- String newQuotedPassword = "\"" + sNewPassword + "\"";
- byte[] newUnicodePassword = newQuotedPassword.getBytes("UTF-16LE");
- mods[0] = new ModificationItem(DirContext.REMOVE_ATTRIBUTE, new BasicAttribute("unicodePwd", oldUnicodePassword));
- mods[1] = new ModificationItem(DirContext.ADD_ATTRIBUTE, new BasicAttribute("unicodePwd", newUnicodePassword));
- // Perform the update
- ctx.modifyAttributes(sUserName, mods);
- */
- mods[0] = new ModificationItem(DirContext.REPLACE_ATTRIBUTE, new BasicAttribute("unicodePwd", newUnicodePassword));
- // Perform the update
- ctx.modifyAttributes(userName, mods);
- System.out.println("Reset Password for: " + userName);
- ctx.close();
- }
- catch (NamingException e) {
- System.out.println("Problem resetting password: " + e);
- }
- catch (UnsupportedEncodingException e) {
- System.out.println("Problem encoding password: " + e);
- }
- catch (IOException e) {
- System.out.println("Problem with TLS: " + e);
- }
- }
- }
评论
9 楼
路人甲wxf
2014-05-26
.net可以在不使用证书的情况下修改密码,java做不到吗?
8 楼
Leecupn
2009-08-21
是的,确实是证书没正确导入。后来我解决了。
请问,我能不能添加或删除一个Group呢???
你做过相关项目吗?
还有,一定要通过
String keystore = "F:\\jdk1.5.0_08\\jre\\lib\\security\\cacerts";
System.setProperty("javax.net.ssl.trustStore", keystore);
这种方式来导入证书吗?还有其他方式没有啊?
请问,我能不能添加或删除一个Group呢???
你做过相关项目吗?
还有,一定要通过
String keystore = "F:\\jdk1.5.0_08\\jre\\lib\\security\\cacerts";
System.setProperty("javax.net.ssl.trustStore", keystore);
这种方式来导入证书吗?还有其他方式没有啊?
7 楼
balaschen
2009-08-19
应该是证书没正确导入到keyStord指定的位置
6 楼
balaschen
2009-08-19
你这明显是SSL没配置好。
5 楼
Leecupn
2009-08-17
你好,我用你的方法,但是不知道怎么搞的,报以下异常:
Exception in thread "main" javax.naming.CommunicationException: simple bind failed: 192.168.136.202:636 [Root exception is javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target]
at com.sun.jndi.ldap.LdapClient.authenticate(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.connect(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.<init>(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(Unknown Source)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.ldap.InitialLdapContext.<init>(Unknown Source)
at com.zony.ldap2.AddAdUser.main(AddAdUser.java:29)
Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Unknown Source)
at com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(Unknown Source)
at com.sun.net.ssl.internal.ssl.ClientHandshaker.processMessage(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.processLoop(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.process_record(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.writeRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.AppOutputStream.write(Unknown Source)
at java.io.BufferedOutputStream.flushBuffer(Unknown Source)
at java.io.BufferedOutputStream.flush(Unknown Source)
at com.sun.jndi.ldap.Connection.writeRequest(Unknown Source)
at com.sun.jndi.ldap.LdapClient.ldapBind(Unknown Source)
... 12 more
能帮助我吗??
谢谢
Exception in thread "main" javax.naming.CommunicationException: simple bind failed: 192.168.136.202:636 [Root exception is javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target]
at com.sun.jndi.ldap.LdapClient.authenticate(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.connect(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.<init>(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(Unknown Source)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.ldap.InitialLdapContext.<init>(Unknown Source)
at com.zony.ldap2.AddAdUser.main(AddAdUser.java:29)
Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.fatal(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.fatalSE(Unknown Source)
at com.sun.net.ssl.internal.ssl.ClientHandshaker.serverCertificate(Unknown Source)
at com.sun.net.ssl.internal.ssl.ClientHandshaker.processMessage(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.processLoop(Unknown Source)
at com.sun.net.ssl.internal.ssl.Handshaker.process_record(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.writeRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.AppOutputStream.write(Unknown Source)
at java.io.BufferedOutputStream.flushBuffer(Unknown Source)
at java.io.BufferedOutputStream.flush(Unknown Source)
at com.sun.jndi.ldap.Connection.writeRequest(Unknown Source)
at com.sun.jndi.ldap.LdapClient.ldapBind(Unknown Source)
... 12 more
能帮助我吗??
谢谢
4 楼
Fire_Wings
2009-04-01
wls981 写道
您好,我也用java通过LDAP修改AD的用户密码,我是用admin修改其他用户的密码的,但是报下面的错误,我导入证书了:Exception in thread "main" javax.naming.OperationNotSupportedException: [LDAP: error code 53 - 0000001F: SvcErr: DSID-031A0FC0, problem 5003 (WILL_NOT_PERFORM), data 0]; remaining name 'cn=wls,cn=Users,dc=gnt,dc=com,dc=cn' at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3078) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2951) at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2758) at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1441) at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:255) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:172) at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:161) at javax.naming.directory.InitialDirContext.modifyAttributes(InitialDirContext.java:148) at test.LdapOperator.changePassword(LdapOperator.java:166) at test.LdapOperator.main(LdapOperator.java:334)请问会是什么原因引起的,我新增用户,修改用户的属性都没有问题,唯独修改密码不行。谢谢!
你的密码不符合密码策略,换个符合策略的密码就行了,我也遇到了这种情况,换个密码是一种解决方案
3 楼
wls981
2009-01-12
您好,我也用java通过LDAP修改AD的用户密码,我是用admin修改其他用户的密码的,但是报下面的错误,我导入证书了:
Exception in thread "main" javax.naming.OperationNotSupportedException: [LDAP: error code 53 - 0000001F: SvcErr: DSID-031A0FC0, problem 5003 (WILL_NOT_PERFORM), data 0]; remaining name 'cn=wls,cn=Users,dc=gnt,dc=com,dc=cn'
at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3078)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2951)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2758)
at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1441)
at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:255)
at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:172)
at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:161)
at javax.naming.directory.InitialDirContext.modifyAttributes(InitialDirContext.java:148)
at test.LdapOperator.changePassword(LdapOperator.java:166)
at test.LdapOperator.main(LdapOperator.java:334)
请问会是什么原因引起的,我新增用户,修改用户的属性都没有问题,唯独修改密码不行。
谢谢!
Exception in thread "main" javax.naming.OperationNotSupportedException: [LDAP: error code 53 - 0000001F: SvcErr: DSID-031A0FC0, problem 5003 (WILL_NOT_PERFORM), data 0]; remaining name 'cn=wls,cn=Users,dc=gnt,dc=com,dc=cn'
at com.sun.jndi.ldap.LdapCtx.mapErrorCode(LdapCtx.java:3078)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2951)
at com.sun.jndi.ldap.LdapCtx.processReturnCode(LdapCtx.java:2758)
at com.sun.jndi.ldap.LdapCtx.c_modifyAttributes(LdapCtx.java:1441)
at com.sun.jndi.toolkit.ctx.ComponentDirContext.p_modifyAttributes(ComponentDirContext.java:255)
at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:172)
at com.sun.jndi.toolkit.ctx.PartialCompositeDirContext.modifyAttributes(PartialCompositeDirContext.java:161)
at javax.naming.directory.InitialDirContext.modifyAttributes(InitialDirContext.java:148)
at test.LdapOperator.changePassword(LdapOperator.java:166)
at test.LdapOperator.main(LdapOperator.java:334)
请问会是什么原因引起的,我新增用户,修改用户的属性都没有问题,唯独修改密码不行。
谢谢!
2 楼
balaschen
2008-09-04
你AD Server的SSL配置没配好吧,netstat查看有没有打开636端口号
1 楼
haidii
2008-08-20
你好,我用你的方法,不知道怎么搞的,报以下异常:
Exception in thread "main" javax.naming.CommunicationException: simple bind failed: localhost:636 [Root exception is javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake]
at com.sun.jndi.ldap.LdapClient.authenticate(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.connect(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.<init>(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(Unknown Source)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.ldap.InitialLdapContext.<init>(Unknown Source)
at ldap.AddAdUser.main(AddAdUser.java:34)
Caused by: javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.writeRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.AppOutputStream.write(Unknown Source)
at java.io.BufferedOutputStream.flushBuffer(Unknown Source)
at java.io.BufferedOutputStream.flush(Unknown Source)
at com.sun.jndi.ldap.Connection.writeRequest(Unknown Source)
at com.sun.jndi.ldap.LdapClient.ldapBind(Unknown Source)
... 12 more
Caused by: java.io.EOFException: SSL peer shut down incorrectly
at com.sun.net.ssl.internal.ssl.InputRecord.read(Unknown Source)
... 20 more
你能帮助我吗??
谢谢!
Exception in thread "main" javax.naming.CommunicationException: simple bind failed: localhost:636 [Root exception is javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake]
at com.sun.jndi.ldap.LdapClient.authenticate(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.connect(Unknown Source)
at com.sun.jndi.ldap.LdapCtx.<init>(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(Unknown Source)
at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(Unknown Source)
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.init(Unknown Source)
at javax.naming.ldap.InitialLdapContext.<init>(Unknown Source)
at ldap.AddAdUser.main(AddAdUser.java:34)
Caused by: javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(Unknown Source)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.writeRecord(Unknown Source)
at com.sun.net.ssl.internal.ssl.AppOutputStream.write(Unknown Source)
at java.io.BufferedOutputStream.flushBuffer(Unknown Source)
at java.io.BufferedOutputStream.flush(Unknown Source)
at com.sun.jndi.ldap.Connection.writeRequest(Unknown Source)
at com.sun.jndi.ldap.LdapClient.ldapBind(Unknown Source)
... 12 more
Caused by: java.io.EOFException: SSL peer shut down incorrectly
at com.sun.net.ssl.internal.ssl.InputRecord.read(Unknown Source)
... 20 more
你能帮助我吗??
谢谢!
发表评论
-
利用sax和xslt转换csv文件内容
2008-02-03 15:57 3190package jaxp; import java.io.B ... -
通过BOM探测文本文件编码类型
2008-01-24 15:19 2385从tomcat源码抄来的改的: private Object ... -
java mail 纯文本附件乱码的解决方案
2008-01-24 15:16 6119java mail在发送纯文本附件时,当附件内容的编码和jvm ... -
ntdsutil设置AD查询返回最大条目
2008-01-18 16:56 1725AD缺省的最大查询结果为1000个,如果超过1千个,则需要客户 ... -
struts2-layout
2007-11-09 18:17 51testvvvv -
Http基本明文验证
2007-06-13 12:55 1847base64解码使用了novell的实现 java 代码 ... -
如何启用活动目录SSL连接
2007-06-13 10:49 3428ad:http://www.cnblogs.com/chnki ... -
AD User重要属性
2007-06-11 14:55 2187objectClass=User User-Account ... -
ldap 访问AD测试
2007-06-08 16:37 4398java 代码 java 代码 /** ... -
JNDI 连接Windows Active Directory 教程(转)
2007-06-08 16:36 3278个人收藏,来源:http:// ... -
正确认识memcached的缓存失效
2007-05-29 10:56 9624最近javaeye上memcached相当火,不少人把它当作s ... -
webwork结合memcached实现sna架构
2007-05-28 14:04 5789实现思路,使用一个拦截器实现session的处理: ... -
activemq实验
2007-05-17 11:37 2127实验环境:activemq4.1.1/spring1.2.8 ... -
发现用Spring配置事务不爽的一个地方
2007-05-11 16:41 2036举个例子: SomeService implement I ... -
Java Transaction Design Strategies读书笔记
2007-05-14 15:34 2421第一种:Client Owner Transaction Ma ... -
有谁知道银行的跨行转帐是怎么保证交易的原子性和一致性?
2007-05-10 09:18 23032最近在看《Java Transaction Design St ... -
InnerClass引用的外层local final变量,究竟具有什么语义
2006-12-21 18:04 6656先看这段代码: public class ShowAnon ...
相关推荐
配合本人AD域证书导入的配置博客,本代码为AD域用户插入和密码修改
具体功能:能够查看用户、获取用户、新建用户、解锁用户、重置用户密码、禁用或启用用户、删除用户、设置用户属性、查看组添加组、从组中删除用户。内置日志查看工具、锁定/最后登陆时间查看器、属性中英文对照表。
AD-解锁/禁用/用户工具-解锁被锁定的AD账户-禁用AD账户以及 修改密码 支持 解锁、禁用、修改域账号密码 如果需要其他功能请联系我 我在添加谢谢大家支持有问题反馈我处理
先在AD中创建一个tempuserou,保证ADBulkAdmin.exe与users.xlsx在同一目录,目前只支持Office 2007及以上版本,在users.xlsx中的newuser Sheet中输入帐户的相关属性信息,然后点击Run运行即可,新建的帐户会创建到...
记得在Windows 2003 IIS中自带修改域用户密码的ASP网页文件iisadmpwd模块,可以通过web方式修改域用户密码。但是IIS 7上不再支持iisadmpwd功能,正常安装windows server 2008及IIS将不会有iisadmpwd模块。那如何将该...
python操作windows ad 服务,添加用户,修改密码等
提供AD的添加账号,删除账号,修改账号(修改密码)功能,附有详细代码
可进行批量重置密码,默认将密码重置为与帐户相同,全为小写,也可自定义密码进行重置,重置后不会要求用户在下次登录前修改密码。 4. 批量启用/禁用帐户:Xable User。可进行批量启用帐户或禁用帐户。 5. 批量删除...
可进行批量重置密码,默认将密码重置为与帐户相同,全为小写,也可自定义密码进行重置,重置后不会要求用户在下次登录前修改密码。 4. 批量启用/禁用帐户:Xable User。可进行批量启用帐户或禁用帐户。 5. 批量删除...
一款客服管理系统,用户需要自行添加“东进 DJD161A 语音卡”动态链接库“Tc08a32.dll”和“NewSig.dll”文件 二、功能介绍 实现客户、员工、产品的添加、修改、删除 三、注意事项 1、开发环境为Visual Studio ...
LPP是您安装在Active Directory服务器上的模块,当用户尝试更改密码时,该模块使用 检查密码。 使用组策略,可以自定义要对这些密码执行的检查的类型,这些检查将被拒绝或批准,然后提交给目录。 LPP使您能够控制...
Intune –将MAM设备导出,Intune标记设备为企业,动态到静态分发离子组,Monitor Alert Office 365服务,组成员计数,批量添加外部用户共享点,添加到Exchange在线许可证组,多合一Office 365 Powersh
6.最好更改PC的计算机名称,防止加域后无法更改了。 7.重启后,打开控制台, 在右上角有一个旗帜,旁边有个黄色感叹号,点击进入后,进行配制。 8.选择 添加新林 9.输入密码 10.默认都是下一步,提升成功后会自动...
(1)用户管理:对用户信息进行添加、删除、修改和查看 (2)版面管理:对版面信息进行添加、删除、修改和查看 (3)类别管理:对类别信息进行添加、删除、修改和查看 (4)帖子管理:对帖子信息进行添加、删除、修改和查看 ...
活动目录(AD) - 用户密码可以使用和Windows域相同的密码. 可以使用扩展模版xlightFTPdUser,在AD里保存Xlight FTP服务器用户的设置。 支持LDAP - 用户密码可以使用和LDAP相同的密码。可以使用扩展模版xlightFTPdUser,...
管理管理员:修改后台用户密码和删除用户; 添加产品类别:添加产品分类; 管理产品类别:修改产品类别名称,排列序号,和删除产品分类; 发布产品信息:发布产品信息,集成在线编辑器,可以发布图文结合的信息...
AzureAD,Spring Security 5和... 编辑src/main/resources/application.yaml并插入您的Azure AD应用程序的客户端ID和密码。 该应用程序必须至少具有针对Microsoft Graph (不是为新应用程序添加的默认Windows Azure A
后台用户管理增加添加用户功能 2.底部年代改为自动更新 3.后台google地图增加提交到google链接 4.修正某些国外空间不能更改基本配置及更新css和rss、用户不能登录的问题; 5.数据库表名前缀可自定义...
窗体和源文件定义 该功能模块涉及到的窗体名称和文件名见下表 "窗体名称 "窗体文件名 "作用 " "class_name_ad"class_name_add."用于添加自定义" "d "asp "信息 " "EmpMain_modyN"EmpMain_modyNew"用于修改自定义" ...
后台用户管理增加添加用户功能 2.底部年代改为自动更新 3.后台google地图增加提交到google链接 4.修正某些国外空间不能更改基本配置及更新css和rss、用户不能登录的问题; 5.数据库表名前缀可自定义,...