/VeeamLogAnonymizer

Anonymize Veeam Log files

Primary LanguagePythonGNU General Public License v3.0GPL-3.0

Veeam Log Anonymizer

Twitter: JMousqueton

A tool to anonimyze your Veeam logs

VeeamLogAnonymizeris is a python script designed for anonymizing log files generated by Veeam Backup & Replication v12, which may contain sensitive information like server names, IP addresses, email addresses, and more. Anonymizing log files helps protect privacy and confidentiality when sharing or analyzing these logs.

I want to clarify that I'm not a developer by profession, but rather a member of the Veeam community who saw the need for a tool like this. The script has been created out of a passion for data privacy and a desire to contribute to our community.

🆕 Important information

With Eric, another Veeam Vanguard, we're developping a new version in C# to improuve drasticly the performance.

You can find the early stage project here.

⚠️ Disclamer

This script is still as an early stage of development.

⚠️ UNDER CONSTRUCTION ⚠️

I want to make it clear that I am not employed by or associated with Veeam Software in any official capacity. This script, its development, and its distribution are entirely independent efforts. It is not endorsed or supported by Veeam Software.

The script has been created by a member of the Veeam community out of a genuine interest in data privacy and the needs of fellow users. While it is designed to work with Veeam Backup & Replication logs, it is not an official Veeam product, and any issues or concerns related to its use should be directed to me rather than Veeam Software.

Please use this script responsibly and in accordance with your organization's policies and any relevant data privacy regulations. Always ensure that you have proper backups and safeguards in place when making changes to log files.

Thank you for understanding the independent nature of this project.

⚙️ Features

Veeam Log Anonymizer, anonymizes :

  • Veeam Server name
  • Usernames
  • IPs address
  • SMTP Servers
  • vCenter Username
  • Domains
  • vCenter Servers
  • Email
  • vCenter Location

💿 Installation

coming soon

🚀 Usage

You need to files :

  • patterns.json
  • VeeamLogAnonymizer.py

Run the Script: Execute the script by providing the necessary command-line arguments.

-i or --input: Specify the input log file or directory containing log files. -o or --output: Specify the output directory where processed log files will be saved. -f or --force: Optional. Use this flag to force overwrite if output files exist or force the creation of the output directory if it doesn't exist. -m or --mapping: Optional. Use this flag to display the mapping table of anonymized data. -v or --verbose: Optional. Use this flag to display processing information and progress. -D or --dictionary: Optional. Use this flag to output a JSON file with the dictionary of anonymized data.

The script will process the log files, anonymizing specific values such as IP addresses, email addresses, server names, and more. If the -m flag is used, the script will display the mapping between original and anonymized values. If the -D flag is used, a JSON file with the anonymized data dictionary will be generated.

The processed log files will be saved in the output directory specified using the -o flag.

📝 Examples

python3 VeeamLogAnonymizer.py -h

.-.   .-.,---.  ,---.    .--.                   ,-.    .---.    ,--,              .--.  .-. .-. .---.  .-. .-..-.   .-.        ,-. _____  ,---.  ,---.    
\ \ / / | .-'  | .-'   / /\ \ |\    /|         | |   / .-. ) .' .'              / /\ \ |  \| |/ .-. ) |  \| | \ \_/ )/|\    /||(|/___  / | .-'  | .-.\   
 \ V /  | `-.  | `-.  / /__\ \|(\  / |         | |   | | |(_)|  |  __          / /__\ \|   | || | |(_)|   | |  \   (_)|(\  / |(_)   / /) | `-.  | `-'/   
  ) /   | .-'  | .-'  |  __  |(_)\/  |         | |   | | | | \  \ ( _)         |  __  || |\  || | | | | |\  |   ) (   (_)\/  || |  / /(_)| .-'  |   (    
  (_)   |  `--.|  `--.| |  |)|| \  / |         | `--.\ `-' /  \  `-) )         | |  |)|| | |)|\ `-' / | | |)|   | |   | \  / || | / /___ |  `--.| |\ \   
        /( __.'/( __.'|_|  (_)| |\/| |         |( __.')---'   )\____/          |_|  (_)/(  (_) )---'  /(  (_)  /(_|   | |\/| |`-'(_____/ /( __.'|_| \)\  
       (__)   (__)            '-'  '-'         (_)   (_)     (__)                     (__)    (_)    (__)     (__)    '-'  '-'          (__) v 1.0  (__) 
   by Julien Mousqueton (@JMousqueton)
    
usage: VeeamLogAnonymizer.py [-h] [-i INPUT_FILE] [-d INPUT_DIRECTORY] -o OUTPUT_DIRECTORY [-f] [-m] [-v] [-D]

Anonymize your Veeam Backup & Replication logs.

options:
  -h, --help            show this help message and exit
  -i INPUT_FILE, --input INPUT_FILE
                        Input log file
  -d INPUT_DIRECTORY, --directory INPUT_DIRECTORY
                        Input directory containing log files
  -o OUTPUT_DIRECTORY, --output OUTPUT_DIRECTORY
                        Output directory for processed log files
  -f, --force           Force overwrite if output files exist or force the creation of output directory if not exists
  -m, --mapping         Display the mapping table of anonymized data
  -v, --verbose         Display processing files and other information
  -D, --dictionary      output a JSON file with the dictionary of anonymized data

Examples

python3 VeeamLogAnonymizer.py -d ./log -o ./anonymized -f

pyhton3 VeeamLogAnonymizer.py -i ./log/VeeamBackupManager.log -o ./anonymized

and full options :)

python3 VeeamLogAnonymizer.py -d ./log -o ./anonymized -f -m -v -D

Author

👤 Julien Mousqueton

🤝 Contributing

Contributions, issues and feature requests are welcome!

Feel free to check issues page.

🙏🏻 Acknowledgements

For the original idea, the support and the ideas of improvement :

  • Bertrand (Veeam Legend)
  • Eric (Veeam Vanguard)

Show your support

Give a ⭐️ if this project helped you!

📝 License

This project is under GNU GENERAL PUBLIC LICENSE version 3.