# Highlighting IP-Adresses without searching for them

**URL:** <https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887>\
**Category:** Elasticsearch\
**Created:** [November 29, 2012, 1:13pm UTC](https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887 "2012-11-29T13:13:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sven\_Reissmann](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sven_reissmann/32/2506_2.png) [@Sven\_Reissmann](https://discuss.elastic.co/u/Sven_Reissmann)\
**Post date:** [November 29, 2012, 1:13pm UTC](https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887/1 "2012-11-29T13:13:22Z")

</div>

Hi,

is it possible to highlight any IP address inside a filed of type string  
without searching for the IP address?

Say I'm having syslog messages stored in ES and I want to search the  
message field using term: Failed.  
Is there a way to highlight all the IP addresses in the message field of  
the matching documents although I did not search for any IP address?

Thanks for a short hint 🙂  
Sven.

--

---

<div class="post-metadata">

**Author:** ![Robin\_Verlangen](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/robin_verlangen/32/1542_2.png) [@Robin\_Verlangen](https://discuss.elastic.co/u/Robin_Verlangen)\
**Post date:** [November 29, 2012, 1:35pm UTC](https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887/2 "2012-11-29T13:35:23Z")

</div>

Hi Sven,

I think the easiest, and most logical way of solving this is in the  
user-interface. Just pick a valid regex for detecting ip addresses and wrap  
it with a span that has a certain (background)color.

Best regards,

Robin Verlangen  
_Software engineer_  
\*  
\*  
W [http://www.robinverlangen.nl](http://www.robinverlangen.nl)  
E robin@us2.nl

[http://goo.gl/Lt7BC](http://goo.gl/Lt7BC)

Disclaimer: The information contained in this message and attachments is  
intended solely for the attention and use of the named addressee and may be  
confidential. If you are not the intended recipient, you are reminded that  
the information remains the property of the sender. You must not use,  
disclose, distribute, copy, print or rely on this e-mail. If you have  
received this message in error, please contact the sender immediately and  
irrevocably delete this message and any copies.

On Thu, Nov 29, 2012 at 2:13 PM, Sven Reissmann [oo35179831@gmail.com](mailto:oo35179831@gmail.com)wrote:

> Hi,
> 
> is it possible to highlight any IP address inside a filed of type string  
> without searching for the IP address?
> 
> Say I'm having syslog messages stored in ES and I want to search the  
> message field using term: Failed.  
> Is there a way to highlight all the IP addresses in the message field of  
> the matching documents although I did not search for any IP address?
> 
> Thanks for a short hint 🙂  
> Sven.
> 
> --

--

---

<div class="post-metadata">

**Author:** ![Sven\_Reissmann](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sven_reissmann/32/2506_2.png) [@Sven\_Reissmann](https://discuss.elastic.co/u/Sven_Reissmann)\
**Post date:** [November 29, 2012, 2:03pm UTC](https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887/3 "2012-11-29T14:03:15Z")

</div>

Hi,

thanks for your reply.  
This is exactly what I'm doing right now. I was just wondering if it is  
possible to do it directly using elasticsearch.

Regards, Sven.

On Thursday, November 29, 2012 2:13:22 PM UTC+1, Sven Reissmann wrote:

> Hi,
> 
> is it possible to highlight any IP address inside a filed of type string  
> without searching for the IP address?
> 
> Say I'm having syslog messages stored in ES and I want to search the  
> message field using term: Failed.  
> Is there a way to highlight all the IP addresses in the message field of  
> the matching documents although I did not search for any IP address?
> 
> Thanks for a short hint 🙂  
> Sven.

--

---

<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:** [July 6, 2017, 3:02am UTC](https://discuss.elastic.co/t/highlighting-ip-adresses-without-searching-for-them/9887/4 "2017-07-06T03:02:13Z")

</div>

Closed on July 6, 2017, 3:02am UTC


