ecologylab.services.exceptions
Class BadClientException
java.lang.Object
java.lang.Throwable
java.lang.Exception
ecologylab.services.exceptions.BadClientException
- All Implemented Interfaces:
- java.io.Serializable
public class BadClientException
- extends java.lang.Exception
Throw this Exception when we detect that the client is evil or lame.
- Author:
- andruid
- See Also:
- Serialized Form
|
Constructor Summary |
BadClientException(java.lang.String ipNumber,
long timeStamp,
java.lang.String message)
Report that the client has behaved badly, by timing out. |
BadClientException(java.lang.String ipNumber,
java.lang.String message)
Report that the client has behaved badly, by sending an improperly formed message. |
| Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
LOCKOUT_INTERVAL
public static final long LOCKOUT_INTERVAL
- Time for which a seemingly evil host gets locked out. Currently 20 minutes.
- See Also:
- Constant Field Values
REPEAT_OFFENDER_INTERVAL
public static final long REPEAT_OFFENDER_INTERVAL
- Time in which bad responses from a host define it as evil host. Currently 1 minute.
- See Also:
- Constant Field Values
BAD_OFFENSE_THRESHOLD
public static final int BAD_OFFENSE_THRESHOLD
- See Also:
- Constant Field Values
BadClientException
public BadClientException(java.lang.String ipNumber,
java.lang.String message)
- Report that the client has behaved badly, by sending an improperly formed message.
- Parameters:
message -
BadClientException
public BadClientException(java.lang.String ipNumber,
long timeStamp,
java.lang.String message)
- Report that the client has behaved badly, by timing out.
- Parameters:
message -
isEvilHostByNumber
public static boolean isEvilHostByNumber(java.lang.String ipNumber)