# Base64 to Hexadecimal Converter
Converts strings in Base64 to Hexadecimal inside JSON files.
## Example
Consider the following JSON file called `data.json`.
```json
{
"mostRecentMachineHash": {
"data": "BAAAhWHqhD6t35WDLbQjCNThk04glwBqEGfmh27rkoA="
},
"mostRecentVouchersEpochRootHash": {
"data": "XhaRbdkr3XQD9FDIl/N8MDNG7z9LrT8YmigcNvqWnMY="
},
"mostRecentNoticesEpochRootHash": {
"data": "WJfJG6VyF4ndZkW5Z8/UGfd8ALPov88EcFpOyu1wZ9Q="
},
"processedInputs": [
{
"mostRecentMachineHash": {
"data": "VT/WlH6kqOvLt7/e3gOrAQriU7Lgq8QtZD0yh4jeAjc="
},
"voucherHashesInEpoch": {
"targetHash": {
"data": "S0oviQGm0hoFsu01ead/1odUJQO8b09Q5ZGBa6E0wEM="
},
"rootHash": {
"data": "XhaRbdkr3XQD9FDIl/N8MDNG7z9LrT8YmigcNvqWnMY="
}
},
"reports": [
{
"payload": "jcIadw=="
}
]
}
]
}
```
If we run `python -m b64to16 data.json`, we get the following output.
```json
{
"mostRecentMachineHash": {
"data": "0x0400008561ea843eaddf95832db42308d4e1934e2097006a1067e6876eeb9280"
},
"mostRecentVouchersEpochRootHash": {
"data": "0x5e16916dd92bdd7403f450c897f37c303346ef3f4bad3f189a281c36fa969cc6"
},
"mostRecentNoticesEpochRootHash": {
"data": "0x5897c91ba5721789dd6645b967cfd419f77c00b3e8bfcf04705a4ecaed7067d4"
},
"processedInputs": [
{
"mostRecentMachineHash": {
"data": "0x553fd6947ea4a8ebcbb7bfdede03ab010ae253b2e0abc42d643d328788de0237"
},
"voucherHashesInEpoch": {
"targetHash": {
"data": "0x4b4a2f8901a6d21a05b2ed3579a77fd687542503bc6f4f50e591816ba134c043"
},
"rootHash": {
"data": "0x5e16916dd92bdd7403f450c897f37c303346ef3f4bad3f189a281c36fa969cc6"
}
},
"reports": [
{
"payload": "0x8dc21a77"
}
]
}
]
}
```
We can also stream the JSON input through standard input, like `cat data.json | python -m b64to16`.
## Help
Run `python -m b64to16 -h`
Raw data
{
"_id": null,
"home_page": "https://github.com/guidanoli/base64-to-hex-converter",
"name": "base64-to-hex-converter",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": "",
"keywords": "",
"author": "Guilherme Dantas",
"author_email": "guidanoli@hotmail.com",
"download_url": "https://files.pythonhosted.org/packages/a8/34/7518369cc3b211a3253c0be5180641789af12e487d78666402a462118d7c/base64-to-hex-converter-0.4.1.tar.gz",
"platform": null,
"description": "# Base64 to Hexadecimal Converter\n\nConverts strings in Base64 to Hexadecimal inside JSON files.\n\n## Example\n\nConsider the following JSON file called `data.json`.\n\n```json\n{\n \"mostRecentMachineHash\": {\n \"data\": \"BAAAhWHqhD6t35WDLbQjCNThk04glwBqEGfmh27rkoA=\"\n },\n \"mostRecentVouchersEpochRootHash\": {\n \"data\": \"XhaRbdkr3XQD9FDIl/N8MDNG7z9LrT8YmigcNvqWnMY=\"\n },\n \"mostRecentNoticesEpochRootHash\": {\n \"data\": \"WJfJG6VyF4ndZkW5Z8/UGfd8ALPov88EcFpOyu1wZ9Q=\"\n },\n \"processedInputs\": [\n {\n \"mostRecentMachineHash\": {\n \"data\": \"VT/WlH6kqOvLt7/e3gOrAQriU7Lgq8QtZD0yh4jeAjc=\"\n },\n \"voucherHashesInEpoch\": {\n \"targetHash\": {\n \"data\": \"S0oviQGm0hoFsu01ead/1odUJQO8b09Q5ZGBa6E0wEM=\"\n },\n \"rootHash\": {\n \"data\": \"XhaRbdkr3XQD9FDIl/N8MDNG7z9LrT8YmigcNvqWnMY=\"\n }\n },\n \"reports\": [\n {\n \"payload\": \"jcIadw==\"\n }\n ]\n }\n ]\n}\n```\n\nIf we run `python -m b64to16 data.json`, we get the following output.\n\n```json\n{\n \"mostRecentMachineHash\": {\n \"data\": \"0x0400008561ea843eaddf95832db42308d4e1934e2097006a1067e6876eeb9280\"\n },\n \"mostRecentVouchersEpochRootHash\": {\n \"data\": \"0x5e16916dd92bdd7403f450c897f37c303346ef3f4bad3f189a281c36fa969cc6\"\n },\n \"mostRecentNoticesEpochRootHash\": {\n \"data\": \"0x5897c91ba5721789dd6645b967cfd419f77c00b3e8bfcf04705a4ecaed7067d4\"\n },\n \"processedInputs\": [\n {\n \"mostRecentMachineHash\": {\n \"data\": \"0x553fd6947ea4a8ebcbb7bfdede03ab010ae253b2e0abc42d643d328788de0237\"\n },\n \"voucherHashesInEpoch\": {\n \"targetHash\": {\n \"data\": \"0x4b4a2f8901a6d21a05b2ed3579a77fd687542503bc6f4f50e591816ba134c043\"\n },\n \"rootHash\": {\n \"data\": \"0x5e16916dd92bdd7403f450c897f37c303346ef3f4bad3f189a281c36fa969cc6\"\n }\n },\n \"reports\": [\n {\n \"payload\": \"0x8dc21a77\"\n }\n ]\n }\n ]\n}\n```\n\nWe can also stream the JSON input through standard input, like `cat data.json | python -m b64to16`.\n\n## Help\n\nRun `python -m b64to16 -h`\n",
"bugtrack_url": null,
"license": "GNU General Public License v3.0",
"summary": "Base64 to Hexadecimal Converter",
"version": "0.4.1",
"project_urls": {
"Bug Tracker": "https://github.com/guidanoli/base64-to-hex-converter/issues",
"Homepage": "https://github.com/guidanoli/base64-to-hex-converter"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "b5155ba12fd85f1e0f11c06d9583a5b4ca021ce0781563ca4264ba9c54c4117a",
"md5": "ca712b83bdae3692c74523a70f374197",
"sha256": "8ffb69365db43e14de761b43c4ca14bc1bff732c845d056004487fc09aa781f8"
},
"downloads": -1,
"filename": "base64_to_hex_converter-0.4.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "ca712b83bdae3692c74523a70f374197",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 16789,
"upload_time": "2023-07-26T01:37:19",
"upload_time_iso_8601": "2023-07-26T01:37:19.659648Z",
"url": "https://files.pythonhosted.org/packages/b5/15/5ba12fd85f1e0f11c06d9583a5b4ca021ce0781563ca4264ba9c54c4117a/base64_to_hex_converter-0.4.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "a8347518369cc3b211a3253c0be5180641789af12e487d78666402a462118d7c",
"md5": "1db1cd3c6c4326754d23bf06e65a9901",
"sha256": "69a066f8fc1ebff91c08052646b9553b534b9d195bf18105e1e3f5eba7b8324d"
},
"downloads": -1,
"filename": "base64-to-hex-converter-0.4.1.tar.gz",
"has_sig": false,
"md5_digest": "1db1cd3c6c4326754d23bf06e65a9901",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 16164,
"upload_time": "2023-07-26T01:37:20",
"upload_time_iso_8601": "2023-07-26T01:37:20.951486Z",
"url": "https://files.pythonhosted.org/packages/a8/34/7518369cc3b211a3253c0be5180641789af12e487d78666402a462118d7c/base64-to-hex-converter-0.4.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-26 01:37:20",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "guidanoli",
"github_project": "base64-to-hex-converter",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "base64-to-hex-converter"
}