# Search for User Tags (Disabled in LDAP, Removed, Watch List)

**URL:** <https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008>\
**Category:** Log Search\
**Tags:** InsightIDR\
**Created:** [September 4, 2024, 6:13pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008 "2024-09-04T18:13:54Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![btmark](https://discuss.rapid7.com/user_avatar/discuss.rapid7.com/btmark/32/2372_2.png) [@btmark](https://discuss.rapid7.com/u/btmark)\
**Post date:** [September 4, 2024, 6:13pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/1 "2024-09-04T18:13:54Z")

</div>

Is it possible to query using User Tags (Disabled, Removed, Watch List)? Looking to create a detection covering the scenario of a user with any of these user tags (assumption would be they’re no longer with the org) tries to authenticate to a device or service in scope of InsightVM.

I’ve dug through the documentation and log schema and can’t seem to find anything that fits this.

Appreciate any guidance here 🙂

---

<div class="post-metadata">

**Author:** ![mmur\_gt4e](https://discuss.rapid7.com/user_avatar/discuss.rapid7.com/mmur_gt4e/32/1985_2.png) [@mmur\_gt4e](https://discuss.rapid7.com/u/mmur_gt4e)\
**Post date:** [September 5, 2024, 7:59am UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/2 "2024-09-05T07:59:00Z")

</div>

As I know, this is not possible, I opened a support case in the past and I think it was moved to IDEA. But never know about that again.  
Could be actually great.

Otherwise, Disabled or Removed cannot be managed, but you could create you own WatchList in a VARIABLE, and define detection rules using the variable that contains an “array” of accounts

---

<div class="post-metadata">

**Author:** ![jordan\_bacher1](https://discuss.rapid7.com/letter_avatar_proxy/v4/letter/j/8c91f0/32.png) [@jordan\_bacher1](https://discuss.rapid7.com/u/jordan_bacher1)\
**Post date:** [September 5, 2024, 1:44pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/3 "2024-09-05T13:44:14Z")

</div>

Hey folks! I’m a member of the product team here at R7, and have some positive news on this. One of the new things that we are working on is adding some of these fields to be detected on in order to power our migration of UBA rules over to the Detection Rule Library. Once there, you would be able to create Custom Detection Rules using the same syntax as our out of the box rules. In the fullness of time we have thought about how variables can play a role here, and are looking into what we might be able to pre-populate

---

<div class="post-metadata">

**Author:** ![btmark](https://discuss.rapid7.com/user_avatar/discuss.rapid7.com/btmark/32/2372_2.png) [@btmark](https://discuss.rapid7.com/u/btmark)\
**Post date:** [September 5, 2024, 1:57pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/4 "2024-09-05T13:57:05Z")

</div>

Great, thanks for that info Jordan! Can’t wait to try this out once it goes live.

---

<div class="post-metadata">

**Author:** ![mmur\_gt4e](https://discuss.rapid7.com/user_avatar/discuss.rapid7.com/mmur_gt4e/32/1985_2.png) [@mmur\_gt4e](https://discuss.rapid7.com/u/mmur_gt4e)\
**Post date:** [September 6, 2024, 12:03pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/5 "2024-09-06T12:03:43Z")

</div>

Great News Jordan!!

---

<div class="post-metadata">

**Author:** ![antmar904](https://discuss.rapid7.com/letter_avatar_proxy/v4/letter/a/d2c977/32.png) [@antmar904](https://discuss.rapid7.com/u/antmar904)\
**Post date:** [September 23, 2024, 8:34pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/6 "2024-09-23T20:34:13Z")

</div>

Thanks Jordan.  
Today, can variables be added dynamically and not only statically? For example can we build a query while adding a certain “value” to a list/variable then create a detection rule for that?

Also, can you add/remove to variables via the API?

---

<div class="post-metadata">

**Author:** ![antmar904](https://discuss.rapid7.com/letter_avatar_proxy/v4/letter/a/d2c977/32.png) [@antmar904](https://discuss.rapid7.com/u/antmar904)\
**Post date:** [January 15, 2025, 2:49pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/7 "2025-01-15T14:49:13Z")

</div>

Hello All.

Is this in place yet? I’d like to be able to search on user tags in log search such as “service account” “domain admins” “administrators”, etc.

---

<div class="post-metadata">

**Author:** ![david\_smith1](https://discuss.rapid7.com/letter_avatar_proxy/v4/letter/d/cdc98d/32.png) [@david\_smith1](https://discuss.rapid7.com/u/david_smith1)\
**Post date:** [January 15, 2025, 3:15pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/8 "2025-01-15T15:15:23Z")

</div>

No this functionality does not exist in log search @antmar904 - you can only search the logs for exact matches of key/values of what is present in the logs, you cannot query group or tag information that is not present in the logs themselves.

However for building Detection rules you can leverage some of the new meta fields we have added, (these cannot be used in log search as they are only meta fields - they don’t exist in the log itself but they can be referenced in detection rules) such as these keys shown in the migrated Lateral Movement - Administrator Impersonation Detection Rule

This includes users that are members of a privileged group:  
detection\_context.destination\_user.privileged\_groups = /.+/

This includes users that are marked as service accounts  
detection\_context.destination\_user.is\_service\_user != /.+/

 ![Screenshot 2025-01-15 at 9.12.23 AM](https://forum-uploads-hub-prod-1-us-east-1-rapid7-com.s3.dualstack.us-east-1.amazonaws.com/original/2X/a/a658e4eda2b42e83266d8aa39ffd0e8bae3b9958.png)

I hope this helps

David

---

<div class="post-metadata">

**Author:** ![antmar904](https://discuss.rapid7.com/letter_avatar_proxy/v4/letter/a/d2c977/32.png) [@antmar904](https://discuss.rapid7.com/u/antmar904)\
**Post date:** [January 15, 2025, 7:07pm UTC](https://discuss.rapid7.com/t/search-for-user-tags-disabled-in-ldap-removed-watch-list/42008/9 "2025-01-15T19:07:03Z")

</div>

thank you for the explanation.
