GPG 구성을 집에서 회사 컴퓨터로 전송하려고 합니다. 이것이 키를 내보내는 방법입니다.
sms@home-sms:~/Public$ gpg --list-keys
/home/sms/.gnupg/pubring.kbx
----------------------------
pub rsa3072 2023-07-17 [SC]
56D61B8B83BD3E534477DE20061D81ADCE33F311
uid [ultimate] Szymon M. Sabat <[email protected]>
sub rsa3072 2023-07-17 [E]
sms@home-sms:~/Public$ gpg --list-secret-keys
/home/sms/.gnupg/pubring.kbx
----------------------------
sec rsa3072 2023-07-17 [SC]
56D61B8B83BD3E534477DE20061D81ADCE33F311
uid [ultimate] Szymon M. Sabat <[email protected]>
ssb rsa3072 2023-07-17 [E]
sms@home-sms:~/Public$ gpg -a --export >pub.asc
sms@home-sms:~/Public$ cat pub.asc
-----BEGIN PGP PUBLIC KEY BLOCK-----
[key]
-----END PGP PUBLIC KEY BLOCK-----
sms@home-sms:~/Public$ gpg -a --export-secret-keys >sec.asc
sms@home-sms:~/Public$ cat sec.asc
-----BEGIN PGP PRIVATE KEY BLOCK-----
[key]
-----END PGP PRIVATE KEY BLOCK-----
sms@home-sms:~/Public$ ls
pub.asc sec.asc
그런 다음 asc
파일을 다른 컴퓨터에 복사하고 키를 가져올 때(공개 키를 가져오는 데 문제 없음) 오류가 발생했습니다.
sms@ubudev-sms:~/Admin$ gpg --list-keys
gpg: directory '/home/sms/.gnupg' created
gpg: keybox '/home/sms/.gnupg/pubring.kbx' created
gpg: /home/sms/.gnupg/trustdb.gpg: trustdb created
sms@ubudev-sms:~/Admin$ gpg --list-secret-keys
sms@ubudev-sms:~/Admin$ ls
packages.microsoft.gpg pub.asc sec.asc
sms@ubudev-sms:~/Admin$ gpg --import pub.asc
gpg: key 061D81ADCE33F311: public key "Szymon M. Sabat <[email protected]>" imported
gpg: Total number processed: 1
gpg: imported: 1
sms@ubudev-sms:~/Admin$ gpg --import sec.asc
gpg: key 061D81ADCE33F311: "Szymon M. Sabat <[email protected]>" not changed
gpg: key 061D81ADCE33F311/061D81ADCE33F311: error sending to agent: No such file or directory
gpg: error building skey array: No such file or directory
gpg: error reading 'sec.asc': No such file or directory
gpg: import from 'sec.asc' failed: No such file or directory
gpg: Total number processed: 0
gpg: unchanged: 1
gpg: secret keys read: 1
설명이 간단해 보이는데 제가 뭘 잘못하고 있는 걸까요?