Beispiel #1
0
def create_client_key_pair(patient_id, study_id):
    """Generate key pairing, push to database, return sanitized key for client."""
    public, private = encryption.generate_key_pairing()
    key_pair_paths = construct_s3_key_paths(study_id, patient_id)
    s3_upload(key_pair_paths['private'], private, study_id, raw_path=True)
    s3_upload(key_pair_paths['public'], public, study_id, raw_path=True)
    return
Beispiel #2
0
def create_client_key_pair(patient_id, study_id):
    """Generate key pairing, push to database, return sanitized key for client."""
    public, private = generate_key_pairing()
    s3_upload("keys/" + patient_id + "_private", private, study_id)
    s3_upload("keys/" + patient_id + "_public", public, study_id)