com.sun.enterprise.v3.admin
Class LocalPasswordImpl

java.lang.Object
  extended by com.sun.enterprise.v3.admin.LocalPasswordImpl
All Implemented Interfaces:
org.glassfish.hk2.PostConstruct, LocalPassword

@Service
@Scoped(value=org.jvnet.hk2.component.Singleton.class)
public class LocalPasswordImpl
extends Object
implements org.jvnet.hk2.component.PostConstruct, LocalPassword

Manage a local password, which is a cryptographically secure random number stored in a file with permissions that only allow the owner to read it. A new local password is generated each time the server starts. The asadmin client can use it to authenticate when executing local commands, such as stop-domain, without the user needing to supply a password.

Author:
Bill Shannon

Constructor Summary
LocalPasswordImpl()
           
 
Method Summary
 String getLocalPassword()
          Get the local password.
 boolean isLocalPassword(String p)
          Is the given password the local password?
 void postConstruct()
          Generate a local password and save it in the local-password file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalPasswordImpl

public LocalPasswordImpl()
Method Detail

postConstruct

public void postConstruct()
Generate a local password and save it in the local-password file.

Specified by:
postConstruct in interface org.glassfish.hk2.PostConstruct

isLocalPassword

public boolean isLocalPassword(String p)
Is the given password the local password?

Specified by:
isLocalPassword in interface LocalPassword

getLocalPassword

public String getLocalPassword()
Get the local password.

Specified by:
getLocalPassword in interface LocalPassword


Copyright © 2012. All Rights Reserved.