PostgreSQL won’t start: “server.key” has group or world access

I had solved it using .. 1) Enter the relevant directory (use> locate server.key) 2) Back up old server.key link. 3) Copy ssl-cert-snakeoil.key to server.key 4-5) Change its owner & group to postgres 6) Ensure the permissions are 700 or 740 (as requested by error message) Recipe for my Ubuntu 12.04 & postgresql-8.3: sudo cd … Read more

How to sign string with private key

I guess what you say is you know the key pair before hand and want to sign/verify with that. Please see the following code. import java.security.KeyPair; import java.security.KeyPairGenerator; import java.security.NoSuchAlgorithmException; import java.security.Signature; import sun.misc.BASE64Encoder; public class MainClass { public static void main(String[] args) throws Exception { KeyPair keyPair = getKeyPair(); byte[] data = “test”.getBytes(“UTF8”); Signature … Read more

How to Grant permission to user on Certificate private key using powershell?

Here is the Answer. Created a powershell script file AddUserToCertificate.ps1 Here is the content for script file. param( [string]$userName, [string]$permission, [string]$certStoreLocation, [string]$certThumbprint ); # check if certificate is already installed $certificateInstalled = Get-ChildItem cert:$certStoreLocation | Where thumbprint -eq $certThumbprint # download & install only if certificate is not already installed on machine if ($certificateInstalled -eq … Read more

How to find Private Key Location

Files and folders starting with a period (.ssh) are hidden by default. To find private/public key, run this commands: ls -a In your case, run this commands to find the ssh keys: cd ~/.ssh then: ls -a Now you should see the keys like this: . .. id_rsa id_rsa.pub If the keys are not there … Read more