# Auth\_failure\_listeners

**URL:** <https://forum.opensearch.org/t/auth-failure-listeners/1895>\
**Category:** Security\
**Created:** [November 22, 2019, 2:34pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895 "2019-11-22T14:34:43Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![ogulman](https://avatars.discourse-cdn.com/v4/letter/o/9fc29f/32.png) [@ogulman](https://forum.opensearch.org/u/ogulman)\
**Post date:** [November 22, 2019, 2:34pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/1 "2019-11-22T14:34:43Z")

</div>

There is no documentation that describes how to configure auth\_failure\_listeners, with demo configuration it didn’t work:

```
      auth_failure_listeners:
        ip_rate_limiting:
          type: ip
          allowed_tries: 10
          time_window_seconds: 3600
          block_expiry_seconds: 600
          max_blocked_clients: 100000
          max_tracked_clients: 100000
        internal_authentication_backend_limiting:
          type: username
          authentication_backend: intern
          allowed_tries: 10
          time_window_seconds: 3600
          block_expiry_seconds: 600
          max_blocked_clients: 100000
          max_tracked_clients: 100000

```

pls, share knowledge about it, thanks

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [May 20, 2021, 12:36pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/2 "2021-05-20T12:36:34Z")

</div>

@ogulman Did you get this resolved? If not which version of odfe are you using?

---

<div class="post-metadata">

**Author:** ![ogulman](https://avatars.discourse-cdn.com/v4/letter/o/9fc29f/32.png) [@ogulman](https://forum.opensearch.org/u/ogulman)\
**Post date:** [May 20, 2021, 12:50pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/3 "2021-05-20T12:50:54Z")

</div>

@Anthony No, I’ve not. odfe 1.7

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [May 20, 2021, 1:15pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/4 "2021-05-20T13:15:35Z")

</div>

@ogulman I just tested it with this version and it works as expected.

```
authz:    
  ....
auth_failure_listeners:
  ip_rate_limiting:
    type: ip
    allowed_tries: 3
    time_window_seconds: 3600
    block_expiry_seconds: 20
    max_blocked_clients: 100000
    max_tracked_clients: 100000
  internal_authentication_backend_limiting:
    type: username
    authentication_backend: internal        
    allowed_tries: 3
    time_window_seconds: 3600
    block_expiry_seconds: 20
    max_blocked_clients: 100000
    max_tracked_clients: 100000

```

Try to use the above in config.yml, don’t forget to upload new configuration using securityadmin.sh script, then enter wrong password for admin user 5 times, then enter correct password - it should fail until _ **block\_expiry\_seconds** _ is reached.

If that doesn’t work, can describe the behaviour you are seeing?

---

<div class="post-metadata">

**Author:** ![ogulman](https://avatars.discourse-cdn.com/v4/letter/o/9fc29f/32.png) [@ogulman](https://forum.opensearch.org/u/ogulman)\
**Post date:** [May 20, 2021, 3:01pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/5 "2021-05-20T15:01:12Z")

</div>

Starting from 1.0.\* odfe save settings into an index, and If I run _securityadmin.sh_, it will overwrite all my settings that were done from UI.  
Currently, I don’t know how to deal with it.

---

<div class="post-metadata">

**Author:** ![Anthony](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/anthony/32/9939_2.png) [@Anthony](https://forum.opensearch.org/u/Anthony)\
**Post date:** [May 20, 2021, 3:13pm UTC](https://forum.opensearch.org/t/auth-failure-listeners/1895/6 "2021-05-20T15:13:47Z")

</div>

@ogulman You can extract/backup the current settings in the index using -r (–retrieve) option with securityadmin.sh script:

./securityadmin.sh -cd /usr/share/elasticsearch/plugins/opendistro\_security/securityconfig/ -icl -nhnv -cacert /usr/share/elasticsearch/config/root-ca.pem -cert /usr/share/elasticsearch/config/kirk.pem -key /usr/share/elasticsearch/config/kirk-key.pem -h localhost -r

You can then update the config with necessary details and upload it using same command without “-r” option.

Ensure to try this on dev environment first
