self.status(f'\n\n@{nameifnameelse"?"}: Uh yes hello, Operator? I would like to join Komrade, the socialist network. Could you patch me through?',clear=True,pause=True)
whilenotname:
name=self.status(('name','@TheOperator: Of course, Komrade ...?\n@'),clear=False).get('vals',{}).get('name')
print()
self.name=name
self.status(f"@TheOperator: Of course, Komrade @{name}. A fine name. First, though, let me see if by an awkward accident someone has already taken this name.",clear=False)
# does username exist
res=self.exists_on_server()
self.status('I got this result',res,clear=False)
stop
exit()
self.status([
f'@{name}: Uh yes hello, Operator? Could I please register as Komrade @{name}?',
ART_OLDPHONE,
'''@TheOperator: Sure, but it's not safe for me to cut the keys you need. Why don't you do that yourself, and come back to me when you've cut a special "asymmetric" key in half: you can keep both halves, and I'll keep one, that way we'll always know we're talking to each other.''',
f'@{name}: Ok but how do I cut these keys?',
'''@TheOperator: I could, it's not safe yet. Your information will be exposed all over the internet. You should forge your encryption keys first.''',
f'@{name}: Fine, but how do I do that?',
'@TheOperator: Visit the Keymaker.'
])
# get needed metadata
ifnotname:name=self.name
ifnameisNone:
name=input('\nWhat is the name for this account? ')
ifpassphraseisNone:
passphrase=getpass.getpass('\nEnter a memborable password: ')
# if is_group is None:
# is_group = input('\nIs this a group account? [y/N]').strip().lower() == 'y'
# ring ring!
self.status([None,ART_KEY,2],pause=False)
# some info
res=self.status([
# ART_KEY,
f'{ART_KEY}@{name}: Dear @Keymaker, I would like to forge a new set of keys.',
f'''@Keymaker: We will make two. A matching, "asymmetric" pair:''',
'\t1) A "public key" you can share with anyone.',
'\t2) A "private key" other no one can ever, ever see.',
'With both together, you can communicate privately and securely with anyone who also has their own key pair.'
])
whilenotpassphrase:
passphrase1=getpass(f'What is a *memorable* pass word or phrase? Do not write it down.\n@{name}: ')