Next: , Previous: Generating Keys, Up: Tutorial



2.4 Exchanging Keys

Jim, Abe and Beth all wish to work with one another, and trust one another. For monotone to accept this situation, the team members will need to exchange the public parts of their rsa key with each other.

First, Jim exports his public key:

     $ monotone --db=~/jim.db pubkey jim@juicebot.co.jp >~/jim.pubkey

His public key is just a plain block of ASCII text:

     $ cat ~/jim.pubkey
     [pubkey jim@juicebot.co.jp]
     MIGdMA0GCSqGSIb3DQEBAQUAA4GLADCBhwKBgQCbaVff9SF78FiB/1nUdmjbU/TtPyQqe/fW
     CDg7hSg1yY/hWgClXE9FI0bHtjPMIx1kBOig09AkCT7tBXM9z6iGWxTBhSR7D/qsJQGPorOD
     DO7xovIHthMbZZ9FnvyB/BCyiibdWgGT0Gtq94OKdvCRNuT59e5v9L4pBkvajb+IzQIBEQ==
     [end]

Abe also exports his public key:

     $ monotone --db=~/abe.db pubkey abe@juicebot.co.jp >~/abe.pubkey

As does Beth:

     $ monotone --db=~/beth.db pubkey beth@juicebot.co.jp >~/beth.pubkey

Then all three team members exchange keys. The keys are not secret, but the team members must be relatively certain that they are communicating with the person they intend to trust, when exchanging keys, and not some malicious person pretending to be a team member. Key exchange may involve sending keys over an encrypted medium, or meeting in person to exchange physical copies, or any number of techniques. All that matters, ultimately, is for each team member to receive the keys of the others.

So eventually, after key exchange, Jim has Beth's and Abe's public key files in his home directory, along with his own. He tells monotone to read the associated key packets into his database:

     $ monotone --db=~/jim.db read <~/abe.pubkey
     monotone: read 1 packet
     $ monotone --db=~/jim.db read <~/beth.pubkey
     monotone: read 1 packet

Beth and Abe similarly tell monotone to read read the two new public keys they received into their respective databases.