[kaffe] CVS kaffe (robilad): Resynced with GNU Classpath: small cleanups in javax.security

Kaffe CVS cvs-commits at kaffe.org
Sat Oct 23 07:58:29 PDT 2004


PatchSet 5336 
Date: 2004/10/23 14:54:33
Author: robilad
Branch: HEAD
Tag: (none) 
Log:
Resynced with  GNU Classpath: small cleanups in javax.security

2004-10-23  Dalibor Topic  <robilad at kaffe.org>

        * libraries/javalib/javax/security/auth/login/NullConfiguration.java,
        libraries/javalib/javax/security/auth/x500/X500Principal.java,
        libraries/javalib/javax/security/cert/X509Certificate.java,
        libraries/javalib/javax/security/sasl/AuthenticationException.java,
        libraries/javalib/javax/security/sasl/AuthorizeCallback.java,
        libraries/javalib/javax/security/sasl/RealmCallback.java,
        libraries/javalib/javax/security/sasl/RealmChoiceCallback.java,
        libraries/javalib/javax/security/sasl/Sasl.java,
        libraries/javalib/javax/security/sasl/SaslClient.java,
        libraries/javalib/javax/security/sasl/SaslClientFactory.java,
        libraries/javalib/javax/security/sasl/SaslException.java,
        libraries/javalib/javax/security/sasl/SaslServer.java,
        libraries/javalib/javax/security/sasl/SaslServerFactory.java:
        Resynced with GNU Classpath.

        2004-10-20  Michael Koch  <konqueror at gmx.de>

        * javax/security/sasl/SaslClient.java,
        javax/security/sasl/SaslClientFactory.java,
        javax/security/sasl/SaslException.java,
        javax/security/sasl/SaslServer.java,
        javax/security/sasl/SaslServerFactory.java:
        Remvoed CVS tags.

        2004-10-20  Michael Koch  <konqueror at gmx.de>

        * javax/security/auth/login/NullConfiguration.java,
        javax/security/auth/x500/X500Principal.java,
        javax/security/cert/X509Certificate.java,
        javax/security/sasl/AuthenticationException.java,
        javax/security/sasl/AuthorizeCallback.java,
        javax/security/sasl/RealmCallback.java,
        javax/security/sasl/RealmChoiceCallback.java,
        javax/security/sasl/Sasl.java,
        javax/security/sasl/SaslClient.java,
        javax/security/sasl/SaslClientFactory.java,
        javax/security/sasl/SaslException.java,
        javax/security/sasl/SaslServer.java,
        javax/security/sasl/SaslServerFactory.java:
        Cleaned up import statements and copyright notices.

Members: 
	ChangeLog:1.2888->1.2889 
	libraries/javalib/javax/security/auth/login/NullConfiguration.java:1.1->1.2 
	libraries/javalib/javax/security/auth/x500/X500Principal.java:1.4->1.5 
	libraries/javalib/javax/security/cert/X509Certificate.java:1.5->1.6 
	libraries/javalib/javax/security/sasl/AuthenticationException.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/AuthorizeCallback.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/RealmCallback.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/RealmChoiceCallback.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/Sasl.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/SaslClient.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/SaslClientFactory.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/SaslException.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/SaslServer.java:1.1->1.2 
	libraries/javalib/javax/security/sasl/SaslServerFactory.java:1.1->1.2 

Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.2888 kaffe/ChangeLog:1.2889
--- kaffe/ChangeLog:1.2888	Sat Oct 23 13:54:26 2004
+++ kaffe/ChangeLog	Sat Oct 23 14:54:33 2004
@@ -1,5 +1,48 @@
 2004-10-23  Dalibor Topic  <robilad at kaffe.org>
 
+	* libraries/javalib/javax/security/auth/login/NullConfiguration.java,
+	libraries/javalib/javax/security/auth/x500/X500Principal.java,
+	libraries/javalib/javax/security/cert/X509Certificate.java,
+	libraries/javalib/javax/security/sasl/AuthenticationException.java,
+	libraries/javalib/javax/security/sasl/AuthorizeCallback.java,
+	libraries/javalib/javax/security/sasl/RealmCallback.java,
+	libraries/javalib/javax/security/sasl/RealmChoiceCallback.java,
+	libraries/javalib/javax/security/sasl/Sasl.java,
+	libraries/javalib/javax/security/sasl/SaslClient.java,
+	libraries/javalib/javax/security/sasl/SaslClientFactory.java,
+	libraries/javalib/javax/security/sasl/SaslException.java,
+	libraries/javalib/javax/security/sasl/SaslServer.java,
+	libraries/javalib/javax/security/sasl/SaslServerFactory.java:
+	Resynced with GNU Classpath.
+
+	2004-10-20  Michael Koch  <konqueror at gmx.de>
+
+        * javax/security/sasl/SaslClient.java,
+        javax/security/sasl/SaslClientFactory.java,
+        javax/security/sasl/SaslException.java,
+        javax/security/sasl/SaslServer.java,
+        javax/security/sasl/SaslServerFactory.java:
+        Remvoed CVS tags.
+
+	2004-10-20  Michael Koch  <konqueror at gmx.de>
+
+        * javax/security/auth/login/NullConfiguration.java,
+        javax/security/auth/x500/X500Principal.java,
+        javax/security/cert/X509Certificate.java,
+        javax/security/sasl/AuthenticationException.java,
+        javax/security/sasl/AuthorizeCallback.java,
+        javax/security/sasl/RealmCallback.java,
+        javax/security/sasl/RealmChoiceCallback.java,
+        javax/security/sasl/Sasl.java,
+        javax/security/sasl/SaslClient.java,
+        javax/security/sasl/SaslClientFactory.java,
+        javax/security/sasl/SaslException.java,
+        javax/security/sasl/SaslServer.java,
+        javax/security/sasl/SaslServerFactory.java:
+        Cleaned up import statements and copyright notices.
+
+2004-10-23  Dalibor Topic  <robilad at kaffe.org>
+
 	* libraries/javalib/javax/imageio/ImageWriter.java,
 	libraries/javalib/javax/imageio/stream/FileCacheImageInputStream.java:
 	Resynced with GNU Classpath.
Index: kaffe/libraries/javalib/javax/security/auth/login/NullConfiguration.java
diff -u kaffe/libraries/javalib/javax/security/auth/login/NullConfiguration.java:1.1 kaffe/libraries/javalib/javax/security/auth/login/NullConfiguration.java:1.2
--- kaffe/libraries/javalib/javax/security/auth/login/NullConfiguration.java:1.1	Wed Jul 21 01:42:15 2004
+++ kaffe/libraries/javalib/javax/security/auth/login/NullConfiguration.java	Sat Oct 23 14:54:35 2004
@@ -1,25 +1,22 @@
 /* NullConfiguration.java -- no-op default login configuration.
    Copyright (C) 2004 Free Software Foundation, Inc.
 
-This file is part of GNU Crypto.
+This file is part of GNU Classpath.
 
-GNU Crypto is free software; you can redistribute it and/or modify it
-under the terms of the GNU General Public License as published by the
-Free Software Foundation; either version 2, or (at your option) any
-later version.
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
 
-GNU Crypto is distributed in the hope that it will be useful, but
+GNU Classpath is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 General Public License for more details.
 
 You should have received a copy of the GNU General Public License
-along with this program; see the file COPYING.  If not, write to the
-
-   Free Software Foundation Inc.,
-   59 Temple Place - Suite 330,
-   Boston, MA 02111-1307
-   USA
+along with GNU Classpath; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
 
 Linking this library statically or dynamically with other modules is
 making a combined work based on this library.  Thus, the terms and
@@ -36,12 +33,10 @@
 or based on this library.  If you modify this library, you may extend
 this exception to your version of the library, but you are not
 obligated to do so.  If you do not wish to do so, delete this
-exception statement from your version.  */
+exception statement from your version. */
 
 
 package javax.security.auth.login;
-
-import javax.security.auth.AuthPermission;
 
 final class NullConfiguration extends Configuration
 {
Index: kaffe/libraries/javalib/javax/security/auth/x500/X500Principal.java
diff -u kaffe/libraries/javalib/javax/security/auth/x500/X500Principal.java:1.4 kaffe/libraries/javalib/javax/security/auth/x500/X500Principal.java:1.5
--- kaffe/libraries/javalib/javax/security/auth/x500/X500Principal.java:1.4	Wed Jul 21 02:12:46 2004
+++ kaffe/libraries/javalib/javax/security/auth/x500/X500Principal.java	Sat Oct 23 14:54:36 2004
@@ -1,20 +1,20 @@
 /* X500Principal.java -- X.500 principal.
-   Copyright (C) 2004 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
 
-This file is part of GNU Crypto.
+This file is part of GNU Classpath.
 
-GNU Crypto is free software; you can redistribute it and/or modify
+GNU Classpath is free software; you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
 the Free Software Foundation; either version 2, or (at your option)
 any later version.
 
-GNU Crypto is distributed in the hope that it will be useful, but
+GNU Classpath is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 General Public License for more details.
 
 You should have received a copy of the GNU General Public License
-along with GNU Crypto; see the file COPYING.  If not, write to the
+along with GNU Classpath; see the file COPYING.  If not, write to the
 Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
 02111-1307 USA.
 
@@ -38,10 +38,15 @@
 
 package javax.security.auth.x500;
 
+import gnu.java.security.OID;
+import gnu.java.security.der.DER;
+import gnu.java.security.der.DERReader;
+import gnu.java.security.der.DERValue;
+
 import java.io.ByteArrayInputStream;
+import java.io.EOFException;
 import java.io.IOException;
 import java.io.InputStream;
-import java.io.EOFException;
 import java.io.NotActiveException;
 import java.io.ObjectInputStream;
 import java.io.ObjectOutputStream;
@@ -52,7 +57,6 @@
 import java.security.Principal;
 
 import java.util.ArrayList;
-import java.util.Collections;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
@@ -61,14 +65,6 @@
 import java.util.Locale;
 import java.util.Map;
 import java.util.Set;
-import java.util.TreeMap;
-
-import gnu.crypto.der.BitString;
-import gnu.crypto.der.DER;
-import gnu.crypto.der.DEREncodingException;
-import gnu.crypto.der.DERReader;
-import gnu.crypto.der.DERValue;
-import gnu.crypto.der.OID;
 
 public final class X500Principal implements Principal, Serializable
 {
Index: kaffe/libraries/javalib/javax/security/cert/X509Certificate.java
diff -u kaffe/libraries/javalib/javax/security/cert/X509Certificate.java:1.5 kaffe/libraries/javalib/javax/security/cert/X509Certificate.java:1.6
--- kaffe/libraries/javalib/javax/security/cert/X509Certificate.java:1.5	Thu Jun  3 19:42:20 2004
+++ kaffe/libraries/javalib/javax/security/cert/X509Certificate.java	Sat Oct 23 14:54:36 2004
@@ -1,23 +1,22 @@
 /* X509Certificate.java -- base class of X.509 certificates.
-   Copyright (C) 2003  Casey Marshall <rsdio at metastatic.org>
+   Copyright (C) 2004 Free Software Foundation, Inc.
 
-This program is free software; you can redistribute it and/or modify it
-under the terms of the GNU General Public License as published by the
-Free Software Foundation; either version 2 of the License, or (at your
-option) any later version.
+This file is part of GNU Classpath.
 
-This program is distributed in the hope that it will be useful, but
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
 WITHOUT ANY WARRANTY; without even the implied warranty of
 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 General Public License for more details.
 
-You should have received a copy of the GNU General Public License along
-with this program; if not, write to the
-
-   Free Software Foundation, Inc.,
-   59 Temple Place, Suite 330,
-   Boston, MA  02111-1307
-   USA
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
 
 Linking this library statically or dynamically with other modules is
 making a combined work based on this library.  Thus, the terms and
@@ -27,25 +26,23 @@
 As a special exception, the copyright holders of this library give you
 permission to link this library with independent modules to produce an
 executable, regardless of the license terms of these independent
-modules, and to copy and distribute the resulting executable under terms
-of your choice, provided that you also meet, for each linked independent
-module, the terms and conditions of the license of that module.  An
-independent module is a module which is not derived from or based on
-this library.  If you modify this library, you may extend this exception
-to your version of the library, but you are not obligated to do so.  If
-you do not wish to do so, delete this exception statement from your
-version.  */
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module.  An independent module is a module which is not derived from
+or based on this library.  If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so.  If you do not wish to do so, delete this
+exception statement from your version. */
 
 
 package javax.security.cert;
 
 import java.io.ByteArrayInputStream;
 import java.io.InputStream;
-import java.io.IOException;
 
 import java.math.BigInteger;
 
-import java.security.NoSuchAlgorithmException;
 import java.security.Principal;
 import java.security.cert.CertificateFactory;
 
@@ -57,9 +54,6 @@
  * <p><b>This class is deprecated in favor of the {@link
  * java.security.cert.X509Certificate} class. It should not be used in new
  * applications.</b></p>
- *
- * <p><strong>NOTE:</strong> This class is deprecated.
- * Use java.security.cert.X509Certificate instead.</p>
  */
 public abstract class X509Certificate extends Certificate
 {
Index: kaffe/libraries/javalib/javax/security/sasl/AuthenticationException.java
diff -u kaffe/libraries/javalib/javax/security/sasl/AuthenticationException.java:1.1 kaffe/libraries/javalib/javax/security/sasl/AuthenticationException.java:1.2
--- kaffe/libraries/javalib/javax/security/sasl/AuthenticationException.java:1.1	Wed Jul 21 01:42:16 2004
+++ kaffe/libraries/javalib/javax/security/sasl/AuthenticationException.java	Sat Oct 23 14:54:37 2004
@@ -1,47 +1,42 @@
-package javax.security.sasl;
+/* AuthenticationException.java --
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library.  Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module.  An independent module is a module which is not derived from
+or based on this library.  If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so.  If you do not wish to do so, delete this
+exception statement from your version. */
 
-// ----------------------------------------------------------------------------
-// $Id: AuthenticationException.java,v 1.1 2004/07/21 01:42:16 dalibor Exp $
-//
-// Copyright (C) 2003, Free Software Foundation, Inc.
-//
-// This file is part of GNU Crypto.
-//
-// GNU Crypto is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 2, or (at your option)
-// any later version.
-//
-// GNU Crypto is distributed in the hope that it will be useful, but
-// WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-// General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program; see the file COPYING.  If not, write to the
-//
-//    Free Software Foundation Inc.,
-//    59 Temple Place - Suite 330,
-//    Boston, MA 02111-1307
-//    USA
-//
-// Linking this library statically or dynamically with other modules is
-// making a combined work based on this library.  Thus, the terms and
-// conditions of the GNU General Public License cover the whole
-// combination.
-//
-// As a special exception, the copyright holders of this library give
-// you permission to link this library with independent modules to
-// produce an executable, regardless of the license terms of these
-// independent modules, and to copy and distribute the resulting
-// executable under terms of your choice, provided that you also meet,
-// for each linked independent module, the terms and conditions of the
-// license of that module.  An independent module is a module which is
-// not derived from or based on this library.  If you modify this
-// library, you may extend this exception to your version of the
-// library, but you are not obligated to do so.  If you do not wish to
-// do so, delete this exception statement from your version.
-// ----------------------------------------------------------------------------
+
+package javax.security.sasl;
 
 /**
  * <p>This exception is thrown by a SASL mechanism implementation to indicate
@@ -54,55 +49,57 @@
  * instead of <code>AuthenticationException</code> if it is unable to determine
  * the nature of the failure, or if does not want to disclose the nature of the
  * failure, for example, due to security reasons.</p>
- *
- * @version $Revision: 1.1 $
  */
-public class AuthenticationException extends SaslException {
+public class AuthenticationException extends SaslException
+{
 
-   // Constants and variables
-   // -------------------------------------------------------------------------
+  // Constants and variables
+  // -------------------------------------------------------------------------
 
-   // Constructor(s)
-   // -------------------------------------------------------------------------
+  // Constructor(s)
+  // -------------------------------------------------------------------------
 
-   /**
-    * Constructs a new instance of <code>AuthenticationException</code>. The
-    * root exception and the detailed message are <code>null</code>.
-    */
-   public AuthenticationException() {
-      super();
-   }
-
-   /**
-    * Constructs a new instance of <code>AuthenticationException</code> with a
-    * detailed message. The root exception is <code>null</code>.
-    *
-    * @param detail a possibly <code>null</code> string containing details of
-    * the exception.
-    * @see Throwable#getMessage()
-    */
-   public AuthenticationException(String detail) {
-      super(detail);
-   }
-
-   /**
-    * Constructs a new instance of <code>AuthenticationException</code> with a
-    * detailed message and a root exception.
-    *
-    * @param detail a possibly <code>null</code> string containing details of
-    * the exception.
-    * @param ex a possibly <code>null</code> root exception that caused this
-    * exception.
-    * @see Throwable#getMessage()
-    * @see SaslException#getCause()
-    */
-   public AuthenticationException(String detail, Throwable ex) {
-      super(detail, ex);
-   }
+  /**
+   * Constructs a new instance of <code>AuthenticationException</code>. The
+   * root exception and the detailed message are <code>null</code>.
+   */
+  public AuthenticationException()
+  {
+    super();
+  }
+
+  /**
+   * Constructs a new instance of <code>AuthenticationException</code> with a
+   * detailed message. The root exception is <code>null</code>.
+   *
+   * @param detail a possibly <code>null</code> string containing details of
+   * the exception.
+   * @see Throwable#getMessage()
+   */
+  public AuthenticationException(String detail)
+  {
+    super(detail);
+  }
+
+  /**
+   * Constructs a new instance of <code>AuthenticationException</code> with a
+   * detailed message and a root exception.
+   *
+   * @param detail a possibly <code>null</code> string containing details of
+   * the exception.
+   * @param ex a possibly <code>null</code> root exception that caused this
+   * exception.
+   * @see Throwable#getMessage()
+   * @see SaslException#getCause()
+   */
+  public AuthenticationException(String detail, Throwable ex)
+  {
+    super(detail, ex);
+  }
 
-   // Class methods
-   // -------------------------------------------------------------------------
+  // Class methods
+  // -------------------------------------------------------------------------
 
-   // Instance methods
-   // -------------------------------------------------------------------------
+  // Instance methods
+  // -------------------------------------------------------------------------
 }
Index: kaffe/libraries/javalib/javax/security/sasl/AuthorizeCallback.java
diff -u kaffe/libraries/javalib/javax/security/sasl/AuthorizeCallback.java:1.1 kaffe/libraries/javalib/javax/security/sasl/AuthorizeCallback.java:1.2
--- kaffe/libraries/javalib/javax/security/sasl/AuthorizeCallback.java:1.1	Wed Jul 21 01:42:16 2004
+++ kaffe/libraries/javalib/javax/security/sasl/AuthorizeCallback.java	Sat Oct 23 14:54:37 2004
@@ -1,47 +1,42 @@
-package javax.security.sasl;
+/* AuthorizeCallback.java --
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
+
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library.  Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module.  An independent module is a module which is not derived from
+or based on this library.  If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so.  If you do not wish to do so, delete this
+exception statement from your version. */
 
-// ----------------------------------------------------------------------------
-// $Id: AuthorizeCallback.java,v 1.1 2004/07/21 01:42:16 dalibor Exp $
-//
-// Copyright (C) 2003, Free Software Foundation, Inc.
-//
-// This file is part of GNU Crypto.
-//
-// GNU Crypto is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 2, or (at your option)
-// any later version.
-//
-// GNU Crypto is distributed in the hope that it will be useful, but
-// WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-// General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program; see the file COPYING.  If not, write to the
-//
-//    Free Software Foundation Inc.,
-//    59 Temple Place - Suite 330,
-//    Boston, MA 02111-1307
-//    USA
-//
-// Linking this library statically or dynamically with other modules is
-// making a combined work based on this library.  Thus, the terms and
-// conditions of the GNU General Public License cover the whole
-// combination.
-//
-// As a special exception, the copyright holders of this library give
-// you permission to link this library with independent modules to
-// produce an executable, regardless of the license terms of these
-// independent modules, and to copy and distribute the resulting
-// executable under terms of your choice, provided that you also meet,
-// for each linked independent module, the terms and conditions of the
-// license of that module.  An independent module is a module which is
-// not derived from or based on this library.  If you modify this
-// library, you may extend this exception to your version of the
-// library, but you are not obligated to do so.  If you do not wish to
-// do so, delete this exception statement from your version.
-// ----------------------------------------------------------------------------
+
+package javax.security.sasl;
 
 import javax.security.auth.callback.Callback;
 
@@ -49,118 +44,128 @@
  * This callback is used by {@link SaslServer} to determine whether one entity
  * (identified by an authenticated authentication ID) can act on behalf of
  * another entity (identified by an authorization ID).
- *
- * @version $Revision: 1.1 $
  */
-public class AuthorizeCallback implements Callback {
+public class AuthorizeCallback implements Callback
+{
+
+  // Constants and variables
+  // -------------------------------------------------------------------------
 
-   // Constants and variables
-   // -------------------------------------------------------------------------
+  /** @serial The (authenticated) authentication id to check. */
+  private String authenticationID = null;
 
-   /** @serial The (authenticated) authentication id to check. */
-   private String authenticationID = null;
-   /** @serial The authorization id to check. */
-   private String authorizationID  = null;
-   /**
-    * @serial The id of the authorized entity. If null, the id of the authorized
-    * entity is authorizationID.
-    */
-   private String authorizedID  = null;
-   /**
-    * @serial A flag indicating whether the authentication id is allowed to act
-    * on behalf of the authorization id.
-    */
-   private boolean authorized = false;
-
-   // Constructor(s)
-   // -------------------------------------------------------------------------
-
-   /**
-    * Constructs an instance of <code>AuthorizeCallback</code>.
-    *
-    * @param authnID the (authenticated) authentication ID.
-    * @param authzID the authorization ID.
-    */
-   public AuthorizeCallback(String authnID, String authzID) {
-      super();
-
-      this.authenticationID = authnID;
-      this.authorizationID  = authzID;
-   }
-
-   // Class methods
-   // -------------------------------------------------------------------------
-
-   // Instance methods
-   // -------------------------------------------------------------------------
-
-   /**
-    * Returns the authentication ID to check.
-    *
-    * @return the authentication ID to check
-    */
-   public String getAuthenticationID() {
-      return authenticationID;
-   }
-
-   /**
-    * Returns the authorization ID to check.
-    *
-    * @return the authorization ID to check.
-    */
-   public String getAuthorizationID() {
-      return authorizationID;
-   }
-
-   /**
-    * Determines if the identity represented by authentication ID is allowed to
-    * act on behalf of the authorization ID.
-    *
-    * @return <code>true</code> if authorization is allowed; <code>false</code>
-    * otherwise.
-    * @see #setAuthorized(boolean)
-    * @see #getAuthorizedID()
-    */
-   public boolean isAuthorized() {
-      return authorized;
-   }
-
-   /**
-    * Sets if authorization is allowed or not.
-    *
-    * @param authorized <code>true</code> if authorization is allowed;
-    * <code>false</code> otherwise.
-    * @see #isAuthorized()
-    * @see #setAuthorizedID(String)
-    */
-   public void setAuthorized(boolean authorized) {
-      this.authorized = authorized;
-   }
-
-   /**
-    * Returns the ID of the authorized user.
-    *
-    * @return the ID of the authorized user. <code>null</code> means the
-    * authorization failed.
-    * @see #setAuthorized(boolean)
-    * @see #setAuthorizedID(String)
-    */
-   public String getAuthorizedID() {
-      if (!authorized) {
-         return null;
+  /** @serial The authorization id to check. */
+  private String authorizationID  = null;
+
+  /**
+   * @serial The id of the authorized entity. If null, the id of the authorized
+   * entity is authorizationID.
+   */
+  private String authorizedID  = null;
+
+  /**
+   * @serial A flag indicating whether the authentication id is allowed to act
+   * on behalf of the authorization id.
+   */
+  private boolean authorized = false;
+
+  // Constructor(s)
+  // -------------------------------------------------------------------------
+
+  /**
+   * Constructs an instance of <code>AuthorizeCallback</code>.
+   *
+   * @param authnID the (authenticated) authentication ID.
+   * @param authzID the authorization ID.
+   */
+  public AuthorizeCallback(String authnID, String authzID)
+  {
+    super();
+
+    this.authenticationID = authnID;
+    this.authorizationID  = authzID;
+  }
+
+  // Class methods
+  // -------------------------------------------------------------------------
+
+  // Instance methods
+  // -------------------------------------------------------------------------
+
+  /**
+   * Returns the authentication ID to check.
+   *
+   * @return the authentication ID to check
+   */
+  public String getAuthenticationID()
+  {
+    return authenticationID;
+  }
+
+  /**
+   * Returns the authorization ID to check.
+   *
+   * @return the authorization ID to check.
+   */
+  public String getAuthorizationID()
+  {
+    return authorizationID;
+  }
+
+  /**
+   * Determines if the identity represented by authentication ID is allowed to
+   * act on behalf of the authorization ID.
+   *
+   * @return <code>true</code> if authorization is allowed; <code>false</code>
+   * otherwise.
+   * @see #setAuthorized(boolean)
+   * @see #getAuthorizedID()
+   */
+  public boolean isAuthorized()
+  {
+    return authorized;
+  }
+
+  /**
+   * Sets if authorization is allowed or not.
+   *
+   * @param authorized <code>true</code> if authorization is allowed;
+   * <code>false</code> otherwise.
+   * @see #isAuthorized()
+   * @see #setAuthorizedID(String)
+   */
+  public void setAuthorized(boolean authorized)
+  {
+    this.authorized = authorized;
+  }
+
+  /**
+   * Returns the ID of the authorized user.
+   *
+   * @return the ID of the authorized user. <code>null</code> means the
+   * authorization failed.
+   * @see #setAuthorized(boolean)
+   * @see #setAuthorizedID(String)
+   */
+  public String getAuthorizedID()
+  {
+    if (!authorized)
+      {
+        return null;
       }
-      return (authorizedID != null ? authorizedID : authorizationID);
-   }
+    return (authorizedID != null ? authorizedID : authorizationID);
+  }
 
-   /**
-    * Sets the ID of the authorized entity. Called by handler only when the ID
-    * is different from {@link #getAuthorizationID()}. For example, the ID might
-    * need to be canonicalized for the environment in which it will be used.
-    *
-    * @see #setAuthorized(boolean)
-    * @see #getAuthorizedID()
-    */
-   public void setAuthorizedID(String id) {
-      this.authorizedID = id;
-   }
-}
\ No newline at end of file
+  /**
+   * Sets the ID of the authorized entity. Called by handler only when the ID
+   * is different from {@link #getAuthorizationID()}. For example, the ID might
+   * need to be canonicalized for the environment in which it will be used.
+   *
+   * @see #setAuthorized(boolean)
+   * @see #getAuthorizedID()
+   */
+  public void setAuthorizedID(String id)
+  {
+    this.authorizedID = id;
+  }
+}
Index: kaffe/libraries/javalib/javax/security/sasl/RealmCallback.java
diff -u kaffe/libraries/javalib/javax/security/sasl/RealmCallback.java:1.1 kaffe/libraries/javalib/javax/security/sasl/RealmCallback.java:1.2
--- kaffe/libraries/javalib/javax/security/sasl/RealmCallback.java:1.1	Wed Jul 21 01:42:16 2004
+++ kaffe/libraries/javalib/javax/security/sasl/RealmCallback.java	Sat Oct 23 14:54:37 2004
@@ -1,79 +1,75 @@
-package javax.security.sasl;
+/* RealmCallback.java --
+   Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+
+This file is part of GNU Classpath.
+
+GNU Classpath is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Classpath is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU Classpath; see the file COPYING.  If not, write to the
+Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+02111-1307 USA.
 
-// ----------------------------------------------------------------------------
-// $Id: RealmCallback.java,v 1.1 2004/07/21 01:42:16 dalibor Exp $
-//
-// Copyright (C) 2003, Free Software Foundation, Inc.
-//
-// This file is part of GNU Crypto.
-//
-// GNU Crypto is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 2, or (at your option)
-// any later version.
-//
-// GNU Crypto is distributed in the hope that it will be useful, but
-// WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-// General Public License for more details.
-//
-// You should have received a copy of the GNU General Public License
-// along with this program; see the file COPYING.  If not, write to the
-//
-//    Free Software Foundation Inc.,
-//    59 Temple Place - Suite 330,
-//    Boston, MA 02111-1307
-//    USA
-//
-// Linking this library statically or dynamically with other modules is
-// making a combined work based on this library.  Thus, the terms and
-// conditions of the GNU General Public License cover the whole
-// combination.
-//
-// As a special exception, the copyright holders of this library give
-// you permission to link this library with independent modules to
-// produce an executable, regardless of the license terms of these
-// independent modules, and to copy and distribute the resulting
-// executable under terms of your choice, provided that you also meet,
-// for each linked independent module, the terms and conditions of the
-// license of that module.  An independent module is a module which is
-// not derived from or based on this library.  If you modify this
-// library, you may extend this exception to your version of the
-// library, but you are not obligated to do so.  If you do not wish to
-// do so, delete this exception statement from your version.
-// ----------------------------------------------------------------------------
+Linking this library statically or dynamically with other modules is
+making a combined work based on this library.  Thus, the terms and
+conditions of the GNU General Public License cover the whole
+combination.
+
+As a special exception, the copyright holders of this library give you
+permission to link this library with independent modules to produce an
+executable, regardless of the license terms of these independent
+modules, and to copy and distribute the resulting executable under
+terms of your choice, provided that you also meet, for each linked
+independent module, the terms and conditions of the license of that
+module.  An independent module is a module which is not derived from
+or based on this library.  If you modify this library, you may extend
+this exception to your version of the library, but you are not
+obligated to do so.  If you do not wish to do so, delete this
+exception statement from your version. */
+
+
+package javax.security.sasl;
 
 import javax.security.auth.callback.TextInputCallback;
 
 /**
  * This callback is used by {@link SaslClient} and {@link SaslServer} to
  * retrieve realm information.
- *
- * @version $Revision: 1.1 $
  */
-public class RealmCallback extends TextInputCallback {
+public class RealmCallback extends TextInputCallback
+{
+
+  /**
+   * Constructs a <code>RealmCallback</code> with a prompt.
+   *
+   * @param prompt the non-null prompt to use to request the realm information.
+   * @throws IllegalArgumentException if <code>prompt</code> is <code>null</code>
+   * or empty.
+   */
+  public RealmCallback(String prompt)
+  {
+    super(prompt);
+  }
 
-   /**
-    * Constructs a <code>RealmCallback</code> with a prompt.
-    *
-    * @param prompt the non-null prompt to use to request the realm information.
-    * @throws IllegalArgumentException if <code>prompt</code> is <code>null</code>
-    * or empty.
-    */
-   public RealmCallback(String prompt) {
-      super(prompt);
-   }
-
-   /**
-    * Constructs a <code>RealmCallback</code> with a prompt and default realm
-    * information.
-    *
-    * @param prompt the non-null prompt to use to request the realm information.
-    * @param defaultRealmInfo the non-null default realm information to use.
-    * @throws IllegalArgumentException if <code>prompt</code> is <code>null</code>
-    * or empty, or if <code>defaultRealm</code> is empty or <code>null</code>.
-    */
-   public RealmCallback(String prompt, String defaultRealmInfo) {
-      super(prompt, defaultRealmInfo);
-   }
-}
\ No newline at end of file
+  /**
+   * Constructs a <code>RealmCallback</code> with a prompt and default realm
+   * information.
+   *
+   * @param prompt the non-null prompt to use to request the realm information.
+   * @param defaultRealmInfo the non-null default realm information to use.
+   * @throws IllegalArgumentException if <code>prompt</code> is <code>null</code>
+   * or empty, or if <code>defaultRealm</code> is empty or <code>null</code>.
+   */
+  public RealmCallback(String prompt, String defaultRealmInfo)
+  {
+    super(prompt, defaultRealmInfo);
+  }

*** Patch too long, truncated ***




More information about the kaffe mailing list