You need to add the public key part to authorized_keys. The .pem file has the private key. When you ran the program ssh-keygen, it created the .pem file, but it also generated a .pub file. It is the .pub file that you need to append to .ssh/authorized_keys. The following is from the ssh-keygen man page:
Normally this program generates the key and asks for a file in which to store the private key. The public key is
stored in a file with the same name but “.pub” appended. The program also asks for a passphrase. The passphrase
may be empty to indicate no passphrase (host keys must have an empty passphrase), or it may be a string of arbi-
trary length. A passphrase is similar to a password, except it can be a phrase with a series of words, punctua-
tion, numbers, whitespace, or any string of characters you want. Good passphrases are 10-30 characters long, are
not simple sentences or otherwise easily guessable (English prose has only 1-2 bits of entropy per character, and
provides very bad passphrases), and contain a mix of upper and lowercase letters, numbers, and non-alphanumeric
characters. The passphrase can be changed later by using the -p option.
rubberman
Posting Maven
2,581 posts since Mar 2010
Reputation Points: 365
Solved Threads: 308
Skill Endorsements: 52
Ok. Yes, I misunderstood that... :-) Unless the file was mangled for some reason (DOS CR/LF line terminators vs. Unix/Linux LF terminators, for example), then I don't know why Fedora won't work. Anyway, verify that the file is a Linux text file (LF line separators) and not in DOS/Windows format.
rubberman
Posting Maven
2,581 posts since Mar 2010
Reputation Points: 365
Solved Threads: 308
Skill Endorsements: 52