# Possible to use external file as part of filter?

**URL:** <https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398>\
**Category:** Logstash\
**Created:** [July 24, 2018, 2:05pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398 "2018-07-24T14:05:25Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![S\_Chase](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/s_chase/32/33237_2.png) [@S\_Chase](https://discuss.elastic.co/u/S_Chase)\
**Post date:** [July 24, 2018, 2:05pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398/1 "2018-07-24T14:05:26Z")

</div>

6.3.0

I've got certain tags being applied if the message body has certain IP Addresses in it. is it possible to maintain that separate IP address (or username) list in a separate file that the filter can look at along with other filtering actions? my reasoning is it would be easier to maintain a separate file as ip/username changes over time than muck about the regular config file.

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [July 24, 2018, 2:31pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398/2 "2018-07-24T14:31:48Z")

</div>

You could use a translate filter to tag the events.

---

<div class="post-metadata">

**Author:** ![S\_Chase](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/s_chase/32/33237_2.png) [@S\_Chase](https://discuss.elastic.co/u/S_Chase)\
**Post date:** [July 24, 2018, 4:24pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398/3 "2018-07-24T16:24:43Z")

</div>

that would work, not 100% but better than editing the conf files each time.

---

<div class="post-metadata">

**Author:** ![S\_Chase](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/s_chase/32/33237_2.png) [@S\_Chase](https://discuss.elastic.co/u/S_Chase)\
**Post date:** [July 26, 2018, 4:20pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398/4 "2018-07-26T16:20:33Z")

</div>

I have to revise my answer. Initially I was just looking for a shoot-n-go solution but the translate filter ended up really being just what I needed. thanks!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 23, 2018, 4:20pm UTC](https://discuss.elastic.co/t/possible-to-use-external-file-as-part-of-filter/141398/5 "2018-08-23T16:20:38Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
