directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From erodrig...@apache.org
Subject svn commit: rev 56294 - incubator/directory/kerberos/trunk/source/main/org/apache/kerberos/kdc
Date Mon, 01 Nov 2004 23:12:19 GMT
Author: erodriguez
Date: Mon Nov  1 15:12:17 2004
New Revision: 56294

Modified:
   incubator/directory/kerberos/trunk/source/main/org/apache/kerberos/kdc/KdcConfiguration.java
Log:
Updated configuration to allow configurable password-changing service-principal.

Modified: incubator/directory/kerberos/trunk/source/main/org/apache/kerberos/kdc/KdcConfiguration.java
==============================================================================
--- incubator/directory/kerberos/trunk/source/main/org/apache/kerberos/kdc/KdcConfiguration.java
(original)
+++ incubator/directory/kerberos/trunk/source/main/org/apache/kerberos/kdc/KdcConfiguration.java
Mon Nov  1 15:12:17 2004
@@ -25,9 +25,10 @@
 
 public class KdcConfiguration {
 	
-	private static final int DEFAULT_PORT = 88;
-	private static final int BUFFER_SIZE  = 1024;
-	private static final int MINUTE       = 1000 * 60;
+	private static final int DEFAULT_PORT  = 88;
+	private static final int CHANGEPW_PORT = 464;
+	private static final int BUFFER_SIZE   = 1024;
+	private static final int MINUTE        = 1000 * 60;
 	
 	private Properties       _properties = new Properties();
 	private EncryptionType[] _encryptionTypes;
@@ -154,6 +155,19 @@
 			return "true".equalsIgnoreCase((String)_properties.get(key));
 		}
 		return true;
+	}
+	
+	public int getChangepwPort() {
+		String key = "changepw.default.port";
+		if (_properties.containsKey(key)) {
+			return Integer.parseInt((String)_properties.get(key));
+		}
+		return CHANGEPW_PORT;
+	}
+	
+	public KerberosPrincipal getChangepwPrincipal() {
+		String key = "changepw.principal";
+		return new KerberosPrincipal((String)_properties.get(key));
 	}
 	
 	private void prepareEncryptionTypes() {

Mime
View raw message