# Adding SSH key gives error with correct key

**URL:** <https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913>\
**Category:** Bug Reports\
**Created:** [March 23, 2016, 4:23pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913 "2016-03-23T16:23:56Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![dgtlmoon](https://avatars.discourse-cdn.com/v4/letter/d/ecd19e/32.png) [@dgtlmoon](https://discuss.circleci.com/u/dgtlmoon)\
**Post date:** [March 23, 2016, 4:23pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913/1 "2016-03-23T16:23:56Z")

</div>

So I’ve been trying to add a new SSH key at [https://circleci.com/gh/myorganisation/myproject/edit#ssh](https://circleci.com/gh/myorganisation/myproject/edit#ssh) but I keep getting the error “Error: it looks like private key is invalid key. Double check If we can help, contact us.”

My key is roughly

-----BEGIN RSA PRIVATE KEY-----  
MIIEpQIBAAKCAQEAyGoAVjc0bcnrFi/kMIiwwBXlQkvp5cgdLZ5JLZHk2qTDiMcV  
(and a whole lot of the other stuff)  
mCkZRRqQ39em5VaT+ES6XoEgOdJr6P9tcLub0AQ8Wtt1V9RdkykMUhc=  
-----END RSA PRIVATE KEY-----

(yes yes I will make a new key and throw that data away 🙂 )

So it all initially looks correct to me, I saw another post similar where the guy was forgetting the headers, I’ve added 3 other keys no problems

---

<div class="post-metadata">

**Author:** ![menelike](https://avatars.discourse-cdn.com/v4/letter/m/71e660/32.png) [@menelike](https://discuss.circleci.com/u/menelike)\
**Post date:** [March 23, 2016, 6:02pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913/2 "2016-03-23T18:02:45Z")

</div>

don’t waste your time, your key might be valid. [this has been reported before](https://discuss.circleci.com/t/problems-with-submitting-an-ssh-permission/2871)

---

<div class="post-metadata">

**Author:** ![dgtlmoon](https://avatars.discourse-cdn.com/v4/letter/d/ecd19e/32.png) [@dgtlmoon](https://discuss.circleci.com/u/dgtlmoon)\
**Post date:** [March 23, 2016, 6:41pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913/3 "2016-03-23T18:41:01Z")

</div>

ahuh! thanks for the tip! yeah its really stopped our project big time

---

<div class="post-metadata">

**Author:** ![FelicianoTech](https://sea2.discourse-cdn.com/circleci/user_avatar/discuss.circleci.com/felicianotech/32/21348_2.png) [@FelicianoTech](https://discuss.circleci.com/u/FelicianoTech)\
**Post date:** [March 23, 2016, 7:35pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913/4 "2016-03-23T19:35:21Z")

</div>

Please use the thread @menelike posted to follow this issue (linked below as well). It makes it easier to let you guys know what is happening. Thank you.

> [@External Image](https://avatars.discourse-cdn.com/v4/letter/m/22d042/48.png):
>
> After entering a valid private key into Permissions \> SSH Permissions I get the error message: “Error: a private key is required If we can help, contact us.”

---

<div class="post-metadata">

**Author:** ![FelicianoTech](https://sea2.discourse-cdn.com/circleci/user_avatar/discuss.circleci.com/felicianotech/32/21348_2.png) [@FelicianoTech](https://discuss.circleci.com/u/FelicianoTech)\
**Post date:** [March 23, 2016, 7:36pm UTC](https://discuss.circleci.com/t/adding-ssh-key-gives-error-with-correct-key/2913/5 "2016-03-23T19:36:26Z")

</div>

Closed on March 23, 2016, 7:36pm UTC


