Skip to main content

Questions tagged [key-generation]

Key generation is the process of generating keys for cryptography. A key is used to encrypt and decrypt whatever data is being encrypted/decrypted.

33 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
7 votes
0 answers
6k views

Running openssl s_client with an aes encrypted key fails

I'm trying to verify a 2-way SSL connection using the openssl s_client command openssl s_client -connect localhost:8883 -CAfile ca.pem -cert client.crt -key client.key The openssl s_client fails ...
ddewaele's user avatar
  • 221
5 votes
1 answer
2k views

OpenVPN Key Size 1024 vs 2048 and Eavesdrop vs Access?

OpenVPN recommends using a 2048 RSA key size for greater security, however, the hardware I'm using is somewhat weak and defaults to using a 1024 RSA key size. I'm trying to determine if it's worth ...
Harry Muscle's user avatar
4 votes
1 answer
9k views

Using PBKDF2 for hash and AES key generation implementation

I am writing a Java application that is required to locally authenticate a user with a password and then use the password to generate an AES-256 key for local file encryption/decryption. I understand ...
dFrancisco's user avatar
  • 2,741
4 votes
0 answers
938 views

What is the openssl equivalent of using java's KeyPairGenerator?

I have been using java's KeyPairGenerator in order to generate public/private keys within a program so that I can encrypt and decrypt files(also using java encrypt/decrypt methods). I want to be able ...
void.massive's user avatar
3 votes
2 answers
1k views

SSH XMSS keypair generation and best practices

In a recent ssh -vv output, I saw OpenSSH mentioning a private key file id_xmss. XMSS is defined in RFC 8391, "XMSS: eXtended Merkle Signature Scheme", May 2018. OpenSSH has experimental ...
Tom Hale's user avatar
  • 3,035
2 votes
0 answers
315 views

Is it possible to regenerate the stub private key from just the physical key in OpenSSH?

Let's say I make an id of type ed25519-sk and have it reside on my yubikey. OpenSSH makes two files, id_ed25519_sk, a stub private key, and id_ed25519_sk.pub the corresponding public key. If I lose ...
nimish's user avatar
  • 121
2 votes
0 answers
117 views

What are the exact stepts made to establish a ssh connection?

From what I've read, I was able to deduce a number of steps but I am not sure if they cover all action or if they are 100% correct. Initial setup for client Enables ssh service Initial setup for ...
Mihai Podaru's user avatar
2 votes
0 answers
183 views

Key Management and Authentication in Note Taking App with Client-Side Encryption

I've been working for some time on a pet project of mine: a note-taking application similar to Evernote with the difference that all content is client-side encrypted. I would like to get some feedback ...
Oliver Weichhold's user avatar
2 votes
0 answers
411 views

Algorithm to generate (and verify) string of 4 quad alpha numeric code

I am writing a system, for which I need to generate unique transaction numbers (which can be verified by myself). I want to use something similar to that used by credit cards, where a string of the ...
Homunculus Reticulli's user avatar
2 votes
0 answers
380 views

Safe to Encrypt ClientId (Integer value) to use as Client Key?

Asked a follow up question (see this link). Based on my understanding, I have to issue an unique ClientId and Client Secret Key to the API subscribers right after the registration phase (client lives ...
Coder Absolute's user avatar
2 votes
0 answers
98 views

Question regarding RFC7296 (IKEv2) PRF+

In RFC 7296, in section 2.13 What do the "K", "S", and T# represent? And my follow-up question is, in section 2.14 What would be the K, S, and T# equivalent in {SK_d | SK_ai | ...
David's user avatar
  • 21
1 vote
0 answers
144 views

Reusing content-encryption key in cms enveloped data

OpenSSL keeps the structure CMS_ContentInfo opaque and in the case of enveloped data generates and manages the content-encryption key completely by itself. It is not possible to provide a content-...
phlipsy's user avatar
  • 111
1 vote
0 answers
1k views

Compatibility advantages of RSA-4096 over RSA-3072

I am targeting a security level of 128 bits for GnuPG, so I am using SHA-256 and AES-128. Now I need to choose between RSA-3072 and RSA-4096. According to multiple sources RSA-3072 security level is ...
user3368561's user avatar
1 vote
0 answers
341 views

Vulnerable Keys? CVE-2008-0166 openssl DSA Key Signature Blacklist coverage?

Would the current set of DSA key blacklists detect a DSA key that was generated with openssl on an affected/vulnerable system, BUT whose DSA parameters (dsaparam) were generated on an unaffected ...
rickhg12hs's user avatar
1 vote
0 answers
136 views

Key derivation usage for deep-level data storage

Let's say I have the following security scheme: Master entity | | v Group entity-----> Child entity 1 | |-----> Child entity 2 | \-----> Child entity 3 ...
alexandernst's user avatar
1 vote
0 answers
160 views

key hierarchy management and master key

Now, I have this equation, {{K_ab}K_bs}K_as. K_ab is encrypted by K_bs then whole packet is encrypted by K_as I think the key structure is K_as is the master key, K_bs is under K_as and K_ab is the ...
Ricky's user avatar
  • 135
1 vote
0 answers
544 views

National ID analysis and generator?

A National ID in my country consists of 14 digits: CYYMMDDXXZZZZ1C1 Where: C refers to the century - 2 for those born between 1900 and 1999, 3 for those born between 2000 to 2099 YYMMDD - birth ...
user91289's user avatar
1 vote
0 answers
112 views

Wireless entry systems why not use pre-shared noise?

I think the title question speaks for itself, but here are the details: You have 4 bits for the buttons, 16 bits for the counter, and a fix 16 bit ID. The transmitter would send out these bits plus ...
Miklos Bence's user avatar
1 vote
1 answer
324 views

Uses for TR-31 Key Version Number?

The standard for TR-31 (and Thales) Key blocks (ref) have a field for "Key Version Number", which is only defined in the spec as Two-digit ASCII character version number, optionally used to ...
Bobson's user avatar
  • 1,475
0 votes
1 answer
169 views

Is This Perfect Forward Secrecy?

I have a textbook that contains the following problem: In practice, one master key, KM, is exchanged in a secure way (e.g. Diffie-Hellman key exchange) between the involved parties. Afterwards, ...
Paul Ratazzi's user avatar
0 votes
0 answers
103 views

Stateless Key Management

I'm looking into the differences between stateful and stateless key management. I understand that stateful key management means that I have a database that tracks my keys, and can become very large. ...
Shane Quintard's user avatar
0 votes
0 answers
106 views

Is pass -> [via pbkdf2] -> seed -> ECDSA key pair better than pass(word) hashing?

For a web service, I am considering generating random 25-49 recovery codes as a kind of pass that can be stored in a pass manager (no usernames). Instead of pass(word) hashing on the server, I ...
r j's user avatar
  • 138
0 votes
0 answers
180 views

How does user activity affect entropy generation process in GnuPG?

Earlier today, I was using gpg to generate keys for work. While doing so, I noticed: We need to generate a lot of random bytes. It is a good idea to perform some other action (type on the keyboard, ...
Rahul Dixit's user avatar
0 votes
0 answers
143 views

Create "bare" pgp private key / Make private key without being able to generate the public key from it

How do you create a private-key/public-key pair without the public key's information in the private key? So you should basically not be able to extract the public key from the private key. The private ...
Myzel394's user avatar
  • 142
0 votes
0 answers
118 views

The hidden perils of trying to handle bad rare outcomes

I vaguely remember some story about some cipher (I think it was 3DES) having some "issue" where if the key happened to be especially bad (like 0x00000...) then the resulting encryption ...
Phil Frost's user avatar
0 votes
0 answers
424 views

symmetric key generation in TLS 1.3

Am trying to understand the phase where the symmetric key is getting generating. From what I am understanding Diffie-Hellman is used to derive the symmetric key in TLS1.3 I am reading this tls ...
loutsi1's user avatar
  • 51
0 votes
0 answers
304 views

Client-side encryption of data, but the server can also add data without reading stored data

For a new application I'd like to store messages for each user's account on a centralized server. The user accesses the application through a SPA javascript web app through their browser. These ...
fli's user avatar
  • 1
0 votes
2 answers
330 views

derived key from email + password?

When deriving a private key from a password, will the resulting secret key be any weaker if the user email is included in the function input? Meaning, user email concatenated with the user password. ...
rm.rf.etc's user avatar
  • 109
0 votes
0 answers
171 views

Which encryption algorithm for cloud backup?

I want to backup my data to the cloud. Before that, I want to encrypt it using GPG (gpg (GnuPG) 2.2.11 and libgcrypt 1.8.4). The backup is just for me, so I don't care about interoperability I only ...
me.at.coding's user avatar
0 votes
0 answers
2k views

Generate symmetric key programmatically using openssl EVP

Am learning OpenSSL EVP API and trying to understand the ways to generate a symmetric key using OpenSSL EVP in C++ program. I have two questions in this regard: 1) To understand what the command ...
kee's user avatar
  • 11
0 votes
0 answers
101 views

Distribution of key by server

I have read that in asymmetric cryptography, a system admin can generate key pairs on the server. After that, the users will be given the generated key pairs and this is an efficient way of doing this ...
xcoder's user avatar
  • 137
0 votes
0 answers
299 views

How should I organize my keys?

Suppose I have a set of computers with variegate level of trust (for example): I fully trust my own desktop pc at home I trust a bit also my smartphone, but I know it could be stolen I trust a bit ...
Giacomo Tesio's user avatar
-1 votes
1 answer
606 views

Does a private key file created with a passphrase need to be decrypted before use

Let's say that I have created a private key file with some passphrase in ssh-keygen. Now someone sends me a message encrypted with my public key. To decrypt the message I need a private key. Do I ...
VVK's user avatar
  • 107