У нас вы можете посмотреть бесплатно Masking Secrets in JSON Data with Logstash Filters или скачать в максимальном доступном качестве, видео которое было загружено на ютуб. Для загрузки выберите вариант из формы ниже:
Если кнопки скачивания не
загрузились
НАЖМИТЕ ЗДЕСЬ или обновите страницу
Если возникают проблемы со скачиванием видео, пожалуйста напишите в поддержку по адресу внизу
страницы.
Спасибо за использование сервиса ClipSaver.ru
Learn how to effectively mask sensitive information in JSON data using Logstash filters. This guide explains the process step-by-step to help you enhance data security. --- This video is based on the question https://stackoverflow.com/q/74638256/ asked by the user 'Kermit' ( https://stackoverflow.com/u/1087984/ ) and on the answer https://stackoverflow.com/a/74688084/ provided by the user 'FredvN' ( https://stackoverflow.com/u/8052787/ ) at 'Stack Overflow' website. Thanks to these great users and Stackexchange community for their contributions. Visit these links for original content and any more details, such as alternate solutions, latest updates/developments on topic, comments, revision history etc. For example, the original title of the Question was: Logstash filter - mask secrets in json data / replace specific keys values Also, Content (except music) licensed under CC BY-SA https://meta.stackexchange.com/help/l... The original Question post is licensed under the 'CC BY-SA 4.0' ( https://creativecommons.org/licenses/... ) license, and the original Answer post is licensed under the 'CC BY-SA 4.0' ( https://creativecommons.org/licenses/... ) license. If anything seems off to you, please feel free to write me at vlogize [AT] gmail [DOT] com. --- Masking Secrets in JSON Data with Logstash Filters: A Guide In today's digital age, ensuring the security of sensitive information is paramount, especially when dealing with logs and data that may be visible in platforms like Kibana. If you're using Logstash to process JSON data and want to mask secrets before they appear in your dashboards, you've come to the right place! This post will walk you through the steps needed to effectively mask sensitive information in your JSON data. The Problem: Masking Sensitive Data You may be facing a common issue where your JSON logs contain sensitive elements, such as passwords or API keys, that should remain confidential. For example, consider the following JSON data structure that includes sensitive information within the postData field: [[See Video to Reveal this Text or Code Snippet]] In this JSON structure, secret and secret2 contain sensitive information that you want to mask when the data is processed through Logstash so that they display as [secret] instead of the actual values. The Solution: Updating Your Logstash Filter Your initial approach to using a Logstash filter is on the right track, but there are modifications needed to correctly mask the values. Let’s break down how to achieve this. Step 1: Splitting the Payloads Initially, your Logstash filter splits the JSON array of payloads properly, converting it into a flat structure. This is a good start! Ensure that you are removing the original payloads field afterward, as you've done: [[See Video to Reveal this Text or Code Snippet]] Step 2: Parsing the Inner JSON Next, parse the inner JSON contained in the postData using the JSON filter. It appears that you have this part correct. However, you'll need to adjust how you access the secret fields after splitting the array. Step 3: Masking the Secrets After splitting, secret and secret2 fields are now nested within postData. Therefore, your current implementation for removing and adding fields needs to be altered. Here is the updated code snippet for correctly masking the secrets: [[See Video to Reveal this Text or Code Snippet]] Key Takeaway Make sure to reference the postData field from the parsedJson structure. This adjustment will correctly replace secret and secret2 with [secret], ensuring that confidential information does not appear in your logs or Kibana displays. Conclusion By following the steps outlined above, you can mask sensitive secrets in your JSON data with Logstash filters. Remember, it's critical to keep your logs clean from any sensitive information to protect your users and your organization. Use the techniques described here to enhance the security of your logging processes and maintain confidentiality. With this guide, you're well-equipped to handle sensitive data securely in your Logstash workflows. If you have any further questions or need assistance, feel free to reach out. Happy logging!