# Timestamp in Windows event message encoded ANSI/Windows-12 adds garbage value when converted in utf8 by winlogbeat

**URL:** <https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069>\
**Category:** Beats\
**Tags:** winlogbeat\
**Created:** [March 8, 2022, 10:03am UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069 "2022-03-08T10:03:21Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Raunak17](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/raunak17/32/102740_2.png) [@Raunak17](https://discuss.elastic.co/u/Raunak17)\
**Post date:** [March 8, 2022, 10:03am UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069/1 "2022-03-08T10:03:21Z")

</div>

The windows event message is below

 ![event](https://us1.discourse-cdn.com/elastic/original/3X/9/c/9c62abd91dd86109717a0d190f7d425b29ba9736.png)

when converted to utf8, it is adding garbage value

"The system time has changed to â€Ž2022â€Ž-â€Ž03â€Ž-â€Ž08T09:51:08.763000000Z from â€Ž2022â€Ž-â€Ž03â€Ž-â€Ž08T09:50:14.842044400Z."

Winlogbeat directly read the message as utf8, which results the addition of garbage value in the message.

Is there any way to read in ANSI/Windows-12 encoded message and then convert it into utf-8 format?

---

<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:** [April 5, 2022, 12:03pm UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069/2 "2022-04-05T12:03:28Z")

</div>

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

---

<div class="post-metadata">

**Author:** ![andrewkroh](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrewkroh/32/3784_2.png) [@andrewkroh](https://discuss.elastic.co/u/andrewkroh)\
**Post date:** [July 12, 2022, 7:57pm UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069/3 "2022-07-12T19:57:56Z")

</div>



---

<div class="post-metadata">

**Author:** ![andrewkroh](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/andrewkroh/32/3784_2.png) [@andrewkroh](https://discuss.elastic.co/u/andrewkroh)\
**Post date:** [July 12, 2022, 8:00pm UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069/4 "2022-07-12T20:00:41Z")

</div>

Could you run the Winlogbeat event reader for that channel with the [`include_xml: true`](https://www.elastic.co/guide/en/beats/winlogbeat/current/configuration-winlogbeat-options.html#_event_logs_include_xml) config option. Then share the raw JSON document produced by Winlogbeat that contains everything including the XML. This will help me understand what is happening.

---

<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:** [November 4, 2022, 8:34am UTC](https://discuss.elastic.co/t/timestamp-in-windows-event-message-encoded-ansi-windows-12-adds-garbage-value-when-converted-in-utf8-by-winlogbeat/299069/5 "2022-11-04T08:34:31Z")

</div>


