Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void userSignUp(String credentials){
- String[] received = simpleprotocol.decodeMessage(credentials);
- String username = received[1];
- String password = received[2];
- if(!(userDetails.containsKey(username))){
- if(username.length() >=5 && username.length() <=20){
- if(password.length() >= 8 && password.length() <=32){
- userDetails.put(username, password);
- }
- }
- }
- try{
- socket.close();
- }catch (IOException e){
- e.printStackTrace();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement