|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectshoddybattle.AccountEditor
public class AccountEditor
This class offers a trivial application for creating a new user account with a specified user level. It should be invoked as follows:
java -cp dist/ShoddyBattle.jar shoddybattle.AccountEditor [PROPERTIES] USER PASSWORD LEVEL
where PROPERTIES is the server properties file to load, USER is the
name of the user account to create, PASSWORD is the password (in plain
text) to give the user account, and LEVEL is the user level (0, 1, or 2)
to assign to the account. If a properties file is not provided then a
default of server.properties
is presumed.
In the future the functionality of this class should be expanded. At present, the main use of this class is for the installer to create to create an administrator account for the server operator.
Constructor Summary | |
---|---|
AccountEditor()
|
Method Summary | |
---|---|
static java.lang.String |
getHash(java.lang.String password)
Return an SHA-1 hash of a password. |
static void |
main(java.lang.String[] args)
Invoke the account editor. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public AccountEditor()
Method Detail |
---|
public static java.lang.String getHash(java.lang.String password) throws java.security.NoSuchAlgorithmException, java.io.UnsupportedEncodingException
java.security.NoSuchAlgorithmException
java.io.UnsupportedEncodingException
public static void main(java.lang.String[] args)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |