[SccriptRunner] - Custom listener in login - Userfailedauthentication envent

Hi, I want to use the Custom listener on the UserAuthenticationfailedInvalidAuthenticationUser event. But I did not find any documentation on this event.

I would like to get some information on the login such as the username used to try to login

What method can I use with UserAuthenticationfailedInvalidAuthenticationUser event Object?

Can you help me?

Thank you

1 answer

1 accepted

0 votes
Accepted answer

Hi Cyril,

There are just a couple of thing you can get from a UserAuthenticationfailedInvalidAuthenticationUser event (Occurs whenever a user fails to authenticate). So for example you can get the username and the timestamp that the event happened

log.debug("User name who failed to login: ${event?.username}")
Date date = new Date(event?.getTimestamp())
log.debug ("Date and time event took place : ${date}")

hope that helps,


Thank you for your answer. It is enough for my need, but for my curiosity where can i find all the attribute and method of the object UserAuthenticationfailedInvalidAuthenticationUser

In the link you sent to me, I did not find anything about "username" or "getTimestamps"


Thank you

There is a bug in the inline script of script runner.

when I  I use "event?.username", scriptrunner tells me :

No such property : username in the class com.atlassian.jira.event.issue.issueEvent

 But it works anyway.

The web interface shows the event object as com.atlassian.jira.event.issue.issueEvent object

and the logs shows the event object as com.atlassian.crowd.event.user.UserAuthenticationFailedInvalidAuthenticationEvent object

So if someone get his code underline, they should not consider the web interface error and execute the code to check in the logs


Suggest an answer

Log in or Sign up to answer
Community showcase
Published Nov 27, 2018 in Portfolio for Jira

Introducing a new planning experience in Portfolio for Jira (Server/DC)

In the past, Portfolio for Jira required a high degree of detail–foresight that was unrealistic for many businesses to   have–in   order to produce a reliable long-term roadmap. We're tur...

2,516 views 15 20
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you