Created
December 19, 2022 21:27
-
-
Save kamack38/f50b29a4ae968a5705d38df7d1b5e82e to your computer and use it in GitHub Desktop.
Aegis export.json to YubiKey converter
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| jq -r '.db.entries[] | [.name, .issuer, .info.algo, .info.secret]| @tsv' <"$1" | | |
| while IFS=$'\t' read -r name issuer algo secret; do | |
| ykman oath accounts add -i "$issuer" -a "$algo" "$name" "$secret" | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment