Sandeep
One of the ways would be to set HTTP_COOKIE response (HTTP_TIP = 1) and associate that with OnAuthAttempt and OnAuthReject. This would ensure that on the scenario wherein the username is incorrect OR password is incorrect a Cookie would be set as "TIP = 1" (CookieName is TIP and value is 1). One can configured the login.html on page load to read cookie value and present a generic message (Which is not obvious as to what really happened i.e. was it a wrong username or was it a correct username but wrong password).
The key point here is you want to remove OR reset the cookie value to something else on successful authentication. If you don't do this. the user may end up seeing the error message always after his 1st unsuccessful attempt, until he clears his cookies off.
REJECT_RESPONSE : HTTP_COOKIE_RESPONSE : TIP = 1.
ACCEPT_RESPONSE : HTTP_COOKIE_RESPONSE : TIP = 0.
REJECT POLICY : Add OnAuthAttempt and OnAuthReject Rule : Associate with REJECT_RESPONSE.
ACCEPT POLICY : Add GET,POST and OnAuthAccept Rule : Associate with ACCEPT_RESPONSE.
Regards
Hubert.