Skip to main content
added 143 characters in body
Source Link
Daneolog
  • 481
  • 3
  • 8
  • 19

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell (Unable to change file permissions on Ubuntu Bash for Windows 10):

enter image description here

  1. Used Powershell to try to place restrictions on the file (https://stackoverflow.com/questions/39404087/pem-file-permissions-on-bash-on-ubuntu-on-windows): enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings (Windows SSH: Permissions for 'private-key' are too open):

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

EDIT: After some reading, it seems that Powershell has some extra ways to reset permissions but I can't seem to find any definitive source.

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell (Unable to change file permissions on Ubuntu Bash for Windows 10):

enter image description here

  1. Used Powershell to try to place restrictions on the file (https://stackoverflow.com/questions/39404087/pem-file-permissions-on-bash-on-ubuntu-on-windows): enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings (Windows SSH: Permissions for 'private-key' are too open):

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell (Unable to change file permissions on Ubuntu Bash for Windows 10):

enter image description here

  1. Used Powershell to try to place restrictions on the file (https://stackoverflow.com/questions/39404087/pem-file-permissions-on-bash-on-ubuntu-on-windows): enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings (Windows SSH: Permissions for 'private-key' are too open):

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

EDIT: After some reading, it seems that Powershell has some extra ways to reset permissions but I can't seem to find any definitive source.

showed previous solutions not working
Source Link
Daneolog
  • 481
  • 3
  • 8
  • 19

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell (Unable to change file permissions on Ubuntu Bash for Windows 10):

enter image description here

  1. Used Powershell to try to place restrictions on the file (https://stackoverflow.com/questions/39404087/pem-file-permissions-on-bash-on-ubuntu-on-windows): enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings (Windows SSH: Permissions for 'private-key' are too open):

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell:

enter image description here

  1. Used Powershell to try to place restrictions on the file: enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings:

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell (Unable to change file permissions on Ubuntu Bash for Windows 10):

enter image description here

  1. Used Powershell to try to place restrictions on the file (https://stackoverflow.com/questions/39404087/pem-file-permissions-on-bash-on-ubuntu-on-windows): enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings (Windows SSH: Permissions for 'private-key' are too open):

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!

Source Link
Daneolog
  • 481
  • 3
  • 8
  • 19

Performing a chmod 400 operation on a .pem file not working no matter what I try

I'm trying to format a .pem file for access to an EC2 instance through SSH, but no matter what I try among suggestions I've seen, nothing seems to work. For context, I have the .pem file stored on my Windows C:// drive.

From just downloading it, I get the following permissions as seen in my WSL shell (and output of ssh command, fails, obviously): enter image description here

The following are my attempts to modify this file

  1. Used Ubuntu's WSL to chmod the file into 400 (what I assume is -r--------): (forgot to unhide my username, lol) enter image description here

1.a. I have modified my wsl.conf with the following to make sure to allow permissions changes to propagate from my WSL shell:

enter image description here

  1. Used Powershell to try to place restrictions on the file: enter image description here

Now, permissions are `-r--r--r--', which still isn't good enough.

enter image description here

  1. Made sure the file is only readable by user in Windows settings:

enter image description here

What else can I do here? This is literally all the answers I've found online and they don't work. Any help is appreciated. Thanks y'all!