Chef PEM file invalid or mis-named?

12,784

Solution 1

From the Administration tab in chef name-validator.pem is generated from Organization level, while name.pem is generated from the User level. You may not have generated the user level pem yet.

Solution 2

This is the issue with client key. I also faced this issue. I regenerated the key for user and added to {user}.pem file and it worked for me.

Share:
12,784
DirtyMikeAndTheBoys
Author by

DirtyMikeAndTheBoys

Updated on June 13, 2022

Comments

  • DirtyMikeAndTheBoys
    DirtyMikeAndTheBoys over 1 year

    My sytem username is myuser but I'm trying to bootstrap machines with a chef-validator.pem and then a blah.pem file, and getting the following error message:

    ERROR: Failed to authenticate to https://mychef01 as blah with key
    /etc/chef/blah.pem.
    Response: Invalid signature for user or client 'blah'
    

    Does this mean that the blah.pem file is invalid, or does it mean that it needs to match my system username (so, myuser.pem)? Either way, what is the root problem and what is the fix?

  • StephenKing
    StephenKing over 7 years
    I think regenerating the validation key is not the best advice for this question (the error message should differ). Be aware that regenerating the validation key invalidates the previous one.
  • user1321759
    user1321759 over 7 years
    Well. I got the same message error and what I wrote solve my problem.
  • Travis Bear
    Travis Bear almost 6 years
    "I regenerated the key" -- you could really improve this answer by providing syntax here.