Mercurial > 510Connectbot
diff src/net/sourceforge/jsocks/server/UserValidation.java @ 349:205ee2873330
update jsocks to 2011-03-19
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Fri, 01 Aug 2014 11:23:10 -0700 |
parents | |
children | 72de889ecfe7 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/net/sourceforge/jsocks/server/UserValidation.java Fri Aug 01 11:23:10 2014 -0700 @@ -0,0 +1,21 @@ +package socks.server; + +/** + Interface which provides for user validation, based on user name + password and where it connects from. +*/ +public interface UserValidation{ + /** + Implementations of this interface are expected to use some or all + of the information provided plus any information they can extract + from other sources to decide wether given user should be allowed + access to SOCKS server, or whatever you use it for. + + @return true to indicate user is valid, false otherwise. + @param username User whom implementation should validate. + @param password Password this user provided. + @param connection Socket which user used to connect to the server. + */ + boolean isUserValid(String username,String password, + java.net.Socket connection); +}