# Adding a second profile later

**URL:** <https://onlykey.discourse.group/t/adding-a-second-profile-later/396>\
**Category:** Uncategorized\
**Created:** [May 27, 2021, 11:58am UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396 "2021-05-27T11:58:32Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ian](https://avatars.discourse-cdn.com/v4/letter/i/bb73d2/32.png) [@Ian](https://onlykey.discourse.group/u/Ian)\
**Post date:** [May 27, 2021, 11:58am UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/1 "2021-05-27T11:58:32Z")

</div>

I’ve run out of slots and would like to safely add a second profile to my existing key, ideally without disturbing my first profile. Has anyone managed to do this after initial setup or can it only be done at the start? Can you restore a backup from a key with only one profile to a key with two?

I tried adding a second PIN through setup to an existing key and although it appeared to work initially I found that none of my slots from the first profile gave out correct TOTP codes any more. So it somehow borked the first profile.

---

<div class="post-metadata">

**Author:** ![bettyvschmartz](https://yyz2.discourse-cdn.com/free1/user_avatar/onlykey.discourse.group/bettyvschmartz/32/81_2.png) [@bettyvschmartz](https://onlykey.discourse.group/u/bettyvschmartz)\
**Post date:** [May 28, 2021, 1:25pm UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/2 "2021-05-28T13:25:59Z")

</div>

Isn’t there an option in the OnlyKey app to _changed secondary PIN_?

– BVS

---

<div class="post-metadata">

**Author:** ![Ian](https://avatars.discourse-cdn.com/v4/letter/i/bb73d2/32.png) [@Ian](https://onlykey.discourse.group/u/Ian)\
**Post date:** [June 1, 2021, 2:06pm UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/3 "2021-06-01T14:06:26Z")

</div>

Yes - this is how I added a secondary PIN to an existing key. But as I say above it kinda worked but the first profile stopped working correctly. I am guessing that the only safe way to do it is at initial setup/after wiping. Just like to understand what’s going on in the hardware and why it has to be this way.

---

<div class="post-metadata">

**Author:** ![bettyvschmartz](https://yyz2.discourse-cdn.com/free1/user_avatar/onlykey.discourse.group/bettyvschmartz/32/81_2.png) [@bettyvschmartz](https://onlykey.discourse.group/u/bettyvschmartz)\
**Post date:** [June 2, 2021, 12:26pm UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/4 "2021-06-02T12:26:07Z")

</div>

The decryption key is derived partly from the PIN so both profiles should have a separate decryption keys AFAIK. Therefore I can’t understand how a second profile would affect the first. If it does, it sounds like a possible bug. May be best to raise an issue with @t11

– BVS

---

<div class="post-metadata">

**Author:** ![t11](https://avatars.discourse-cdn.com/v4/letter/t/8e7dd6/32.png) [@t11](https://onlykey.discourse.group/u/t11)\
**Post date:** [June 2, 2021, 1:33pm UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/5 "2021-06-02T13:33:10Z")

</div>

@Ian What version of app and firmware do you have?

We do mention in the initial setup that the 2nd profile cannot be added later but this should probably be better documented. The reason for this is a bit technical but documented here - [About Security | Docs](https://docs.crp.to/security.html#about-onlykey-pin-profiles-key-derivation-and-encryption)

> - If there is only one profile a Curve25519 shared secret of pinhashpriv and pinhashpub is generated (kek1)
> - If there are two profiles a Curve25519 shared secret of pinhashpriv and pinhashpub2 is generated (kek1)

The kek1 is different with 2 profiles and so that makes the data encrypted in the old profile inaccessible.

---

<div class="post-metadata">

**Author:** ![Ian](https://avatars.discourse-cdn.com/v4/letter/i/bb73d2/32.png) [@Ian](https://onlykey.discourse.group/u/Ian)\
**Post date:** [June 2, 2021, 3:29pm UTC](https://onlykey.discourse.group/t/adding-a-second-profile-later/396/6 "2021-06-02T15:29:22Z")

</div>

Thanks both for your help - I’m on the snap app v5.3.1, firmware v0.2-beta.8c.

I think you’re right that the guidance “second profile…cannot be setup later” only appears in the initial setup. In the Users Guide it appears as a screenshot: [OnlyKey Setup Using OnlyKey App](https://docs.crp.to/usersguide.html#onlykey-setup) but I couldn’t find any other mention or discussions. I thought I’d try and save myself the time of setting up the primary profile again - but it was a bad idea! Turns out I spent a lot more time fixing the resulting issues. All my own fault 🤦‍♂️

The technical reason about shared secret kek1 makes sense - I though there must be some link between the profiles to explain the corruption I saw.

So I think the only safe way to add a second profile to a key you’re already using is to back it up, wipe it and use initial setup to recreate it with two profiles from scratch, then restore your backup.
