Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

Questions tagged [public-key-encryption]

Public-key cryptography (encryption is a misnomer) is the process of creating two keys during the encryption of plain text, one private and one public.

Filter by
Sorted by
Tagged with
0 votes
0 answers
9 views

Postfix use distinct client certificate for upstream server

I have tried to read through the documentation of Postfix TLS support http://www.postfix.org/TLS_README.html here. There is a large amount of flexibility in the smtp_tls setup especially with ...
user avatar
  • 1
0 votes
1 answer
45 views

Convert GPG key to SSH

I'm currently using gpg-agent to authenticate when I use SSH. However, I would like to go back to just using a plain SSH key without GPG being involved. Is there a way to extract my GPG private key ...
user avatar
  • 185
0 votes
1 answer
47 views

passwd: Authentication token manipulation error using ssh and public key

I'm using ssh and public key (saved in my local computer) to connect to a HPC cluster as follows: $ ssh -i ~/narvi_key/xenial-narvi-key alijani@narvi.tut.fi Enter passphrase for key '/home/xenial/...
user avatar
1 vote
3 answers
141 views

Can I get certificates for other recipients of an encrypted email?

I run into this problem fairly often at work using Outlook. There is an email thread going and someone decides to encrypt their response to the group (sometimes justified, sometimes not). Now I want ...
user avatar
  • 287
1 vote
2 answers
7k views

How do I use the openssl command to decode a public key .PEM file?

I have my localhost TSL/SSL certificate from Chrome stored to a .PEM file. Was wondering how do I use the oppenssl command to decode it into a list of human-readable fields. Googling this only ...
user avatar
2 votes
1 answer
69 views

Why Use Deffie Hellmen(Key Exchange) instead of encrypting the symmetric session key with the servers's or client's public key?

If the client generates the symmetric session key and then encrypts in with the server's public key and send it to the server, then only the server can decrypt the encrypted session key with it's ...
user avatar
0 votes
1 answer
45 views

What happens to a message encrypted with an asymmetric key if it arrives corrupted?

I have a theoretical doubt about encryption that I couldn’t find clarified in any of the resources I have. I’d really appreciate anyone clarifying this little doubt for me. I’m studying Asymmetric ...
user avatar
2 votes
1 answer
1k views

Why does gpg's secret and public key have the same keyid?

On my Windows machine running Cygwin, When I run gpg --list-keys --keyid-format LONG gpg --list-secret-keys --keyid-format LONG Both the pub and sec keys have the same value. sub and ssb have the ...
user avatar
  • 47
3 votes
1 answer
166 views

GPG imported and exported public keys do not match

At keyserver.ubuntu.com I look up a public key, say this one, using quux foo as the search string, which when you click on any of the hyperlinks there, say the first one, you get this, the first and ...
user avatar
  • 33
0 votes
1 answer
935 views

Can I perform ECC encryption (like ECIES) with openssl?

I would like to use Elliptic Curve Cryptography to asymmetrically encrypt data. That is encrypt data using a public ECC key, so that only someone with the corresponding private key can decrypt it. I'm ...
user avatar
0 votes
1 answer
296 views

How to un-encrypt a single encrypted field from a file in Linux (openssl, rsa key)

I have a csv file that I receive every day on Linux. The file itself is NOT encrypted as a whole, but one of the fields is, so it looks something like this: data, data, data, encrypted_data, data, ...
user avatar
0 votes
1 answer
111 views

SSH authentication methods questions

These days i look at the SSH protocol and iam trying to figure out how the password and public key authentication methods really work. In password authentication, i know that the client encrypts the ...
user avatar
0 votes
1 answer
823 views

How to encrypt a message by using a .pub file?

I received a file named id_rsa1.pub from a company so I can send them an ecrypted message. But I can't import it to my program "Kleopatra", because the file format is not supported. Unfortunately ...
user avatar
  • 6,442
1 vote
1 answer
140 views

Why does an EFS-encrypted file get decrypted when it gets uploaded to the Internet?

Why is an EFS-encrypted file decrypted when it gets uploaded to the Internet?
user avatar
0 votes
1 answer
86 views

Will the contents of an encrypted file from a local disk be visible to others when uploaded to the Internet?

If I encrypt the contents of a file through File Explorer in Windows 10 (Properties -> Attributes -> Advanced) and upload it to the internet (cloud, attachment in an email, etc.), will I still be the ...
user avatar
0 votes
1 answer
130 views

Is the role of public key/private key determined arbitrarily or mathematically?

I have read about conflicting information about the roles of public/private keys. In one article(Asymmetrical-key algorithms), it says: Simply put each party, say Alice, picks a private random ...
user avatar
1 vote
1 answer
47 views

What's the fundamental principle regarding who should hold which key (public vs. private)?

In a SSH logging scenario, the client keeps the private key while the server stores the public key under its ./ssh directory. In a different scenario, such as SSL, it's the server that keeps the ...
user avatar
0 votes
0 answers
506 views

I want to port forward my ssh connection to my docker container, where I run gitlab

I can ssh to my docker container by giving specific port number like this: ssh -p 8080 git@192.168.0.94 This works fine, and I am getting this: Welcome to GitLab, @malinda! Connection to 192.168.0....
user avatar
1 vote
1 answer
1k views

Extend the expiration date of a GPG key non-interactively

I need to extend the expiration date of a GPG key, but all the answers or articles I can find do it interactively, for example. I need to embed the logic in a shell script, so wondering how can I do ...
user avatar
  • 167
0 votes
1 answer
105 views

Should 'username@hostname' in a public key be distributed together?

Usually, at the end of an RSA public key, you find something like 'username@hostname' by default or something else otherwise you specified. It is said that it is just a comment and doesn't matter at ...
user avatar
1 vote
1 answer
5k views

Unable to load Key pair from p12 certificate - OPENSSL error

I try to extract public and private keys from PKCS#12 certificate with openssl and always have the same error, even i just want to see it without output file (with flag -info) after the certificate ...
user avatar
0 votes
0 answers
30 views

How to create a portable gpgme directory for C/C++ projects

This question is probably quite basic knowledge but here it is. I want to integrate public key encryption, preferably using gpgme, in my projects but the computers running it will not always have ...
user avatar
  • 101
1 vote
1 answer
349 views

Can OpenSSH on Windows Server 2019 employ client certificates created via PowerShell as opposed to ssh-keygen?

I'm really not sure of the core differences between each, but can OpenSSH on Windows Server 2019 employ client certificates created via PowerShell (*.pfx, .cer) as opposed to using public/private key ...
user avatar
0 votes
0 answers
69 views

Is there a maximum number of subkeys in GnuPG?

The GnuPG documentation describes a process to generate subkeys for a gpg-master-key with the option to have different validity settings for subkeys. This works perfectly for a small amount of subkeys,...
user avatar
  • 1
9 votes
3 answers
20k views

How to check if a GPG encrypted file is encrypted using a specific public key?

Consider if a file is encrypted using command e.g. gpg --output test.txt.gpg --encrypt --recipient test@example.com test.txt Now, consider another person received test.txt.gpg the the pub key test@...
user avatar
  • 489
1 vote
1 answer
368 views

limit sftp access to specific folders when using a public/private key with openssh

Is it possible to limit what folders a user can sftp to when using public/private keys? Say I have a server with user1 and their home folder is /home/user1. I already have it configured so user1 can ...
user avatar
4 votes
1 answer
4k views

When is asymmetric and symmetric encryption used in SSH?

I was reading the following document: https://www.digitalocean.com/community/tutorials/understanding-the-ssh-encryption-and-connection-process In the asymmetric encryption it looks like the shared ...
user avatar
19 votes
3 answers
15k views

I got "BEGIN PGP PUBLIC KEY BLOCK" attached to an email and I don't know what it is [duplicate]

Okay, I have no clue what this is, but I just received an email that has this in it. -----BEGIN PGP PUBLIC KEY BLOCK----- [redacted] -----END PGP PUBLIC KEY BLOCK----- If this means something, ...
user avatar
1 vote
1 answer
554 views

How to verify sks-keyservers HKPS certificate?

I’m trying to make sense of how PGP is supposed to be used securely, but coherent and helpful information on the subject is surprisingly hard to find. So, SKS keyservers provide their HKPS ...
user avatar
  • 143
2 votes
0 answers
688 views

setting up key based authentication for windows 10 ssh server and client

I am trying to set up public private key authentication for the windows 10 beta openssh server and client. But i am running into the problem where it still asks for a password. here's what I did. -...
user avatar
1 vote
0 answers
340 views

Windows OpenSSH Public key issue

I have tried my best to get my ssh server configured although every time I try to log in with public key authorisation it comes up with a Server refused public key signature despite accepting key. I ...
user avatar
0 votes
1 answer
1k views

CertUtil | How CertUtil -verifykeys works internally?

I have a CA certificate in Local Machine Certificate Store. When I run this command - enter code here certutil -verifyKeys gives Key "KEYNAME" verifies as the public key for Certificate "KEYNAME" ...
user avatar
  • 103
1 vote
1 answer
156 views

Do I need a PGP key?

I've recently got familiar with the concept of OpenPGP public-private keys, and how to use GnuPG tool to manage PGP keys. I have three questions: 1- Is it necessary for me to have a PGP (or an ...
user avatar
-2 votes
1 answer
2k views

How do I restore a deleted file encryption key on Windows 10?

I deleted my file encryption key from User Certificates in the Control Panel. I understand that Windows does not delete the private key and that User Certificates only deletes the key from the ...
user avatar
  • 823
0 votes
1 answer
419 views

GnuPG outputting rubbish when trying to use the encrypt option

I've been using GnuPG fine for the past year or so, but I haven't encrypted anything directly from the CLI for a while. I've been trying to do it today and this is the weird output I get. Doesn't ...
user avatar
  • 241
3 votes
1 answer
678 views

`gpg --edit-key <user>` not listing public key

I'm trying to understand better how GnuPG works. When I run: gpg --edit-key chloe I would expect to see something like this (from the GnuPG privacy handbook): Secret key is available. pub 1024D/...
user avatar
6 votes
3 answers
6k views

How to encrypt a file using my GPG private key so I can decrypt it later

I have a text file on my GNU/Linux laptop and I want to encrypt it with my GPG private key so I can decrypt it later and see the output. I've tried this: gpg --encrypt file.txt but I'm asked to ...
user avatar
  • 2,553
0 votes
1 answer
126 views

Can't export or list keys

I'm using my desktop to obtain files from a server (using git and rsync), now I want to use my notebook and try therefore to export/import the required RSA-keys. Automatic login from the notebook to ...
user avatar
  • 125
0 votes
2 answers
108 views

What's the simplest way to perform public key encryption?

I'm applying for a job and they asked me to send my SSN to them over e-mail. Call me paranoid, but that doesn't sit well with me. So, I'm looking for a simple form of public-key encryption that a ...
user avatar
4 votes
1 answer
2k views

Cannot export secret key without providing passphrase

I have forgotten my passphrase for my secret GPG key, and I want to export it, so that I can brute force it with a few likely ones. However, running gpg --export-secret-keys will always make the gpg-...
user avatar
0 votes
2 answers
364 views

Knowing when a key becomes compromised

I am trying to determine best practices for identifying a compromised key. I have had very little luck finding any material on this however was hoping there was some kind of service which would notify ...
user avatar
3 votes
2 answers
3k views

When adding a gpg key with homedir parameter error

When adding a key using the cmd Gpg2 –-homedir . –-gen-key And Im getting the error Can’t connect to the agent: Invalid value passed to IPC This is something to do with the homedir parameter but ...
user avatar
1 vote
1 answer
8k views

GPG2 Encryption - No public key error

When I generate my keys using gpg2 --gen-key and then I try to try to encrypt the file using gpg2 --batch --yes -r myemail@test.com --always-trust --homedir . -e test.text I get an error "...
user avatar
5 votes
3 answers
2k views

How does public/private key cryptography work, who generates the key pair?

I have a requirement to encrypt a file, get it to an external partner who will then decrypt the file using a key. My "basic" understanding is that I can generate the public and private keys, encode ...
user avatar
0 votes
1 answer
2k views

gpg does not ask for passphrase on one encrypted file

I have a test encrypted file on my computer that when I run gpg(2) --verify message.txt.asc I get: gpg: Signature made Tue Mar 3 21:16:41 2015 PST using RSA key ID ******* gpg: Good signature ...
user avatar
  • 111
1 vote
0 answers
680 views

Duplicati uses symmetric encryption despite giving the recipient ID_key

I have a question regarding decrypt using gpg asymmetrically. I use duplicity encrypt copies asymmetrically. E.g: `Duplicati.CommandLine.exe backup s3://testduplicatigpg3 C:\Users\test\Desktop\tt --...
user avatar
  • 19
1 vote
1 answer
4k views

How to recover files from infected. Vvv extention [duplicate]

Can any one help for how can remove this virus. Our all computer's files infected from this (.vvv) virus. We are using windows 7 Plz give me strong methods. If you need remote screen i will provide ...
user avatar
  • 19
3 votes
2 answers
974 views

Why does PGP encrypt differently when piping into a file instead of printing the result?

I'll use the following PGP key stored in pub.pem: -----BEGIN PGP PUBLIC KEY BLOCK----- Version: PGPfreeware 6.5.8 for non-commercial use <http://www.pgp.com> ...
user avatar
  • 1,141
3 votes
1 answer
3k views

Why does duplicity require the GnuPG passphrase when rotating backups?

I am using duplicity 0.7.05 to periodically backup a directory that resides on a Linux system, using a GnuPG key pair with an encrypted private key. Since the public key is not encrypted, the ...
user avatar
  • 1,979
3 votes
1 answer
8k views

Outlook missing "Publish to GAL"

Unable to encrypt emails with valid certificates in exchange environment. I just thought of publishing the public keys to GAL but Publish to GAL option is missing Things i've tried : Re-download ...
user avatar
  • 6,075