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.

Filter by
Sorted by
Tagged with
2
votes
2answers
62 views

Password relevance in key derivation function

I'm questioning the password used in a key derivation function, whether It makes sense to make it unique for every generated symmetric key and why
52
votes
4answers
66k views

What are requirements for HMAC secret key?

I'm creating HTTP REST service which will be available over tls only. For authentication purposes I plan to generate JWT token for every user using HMAC HS256. I need a secret key for HMAC. What are ...
6
votes
1answer
4k views

Which ECC to choose with GPG?

I want to generate a key pair with gpg2 2.1.11 and libgcrypt 1.6.5. I use the command gpg2 --expert --full-key-gen. This allows me to choose an ECC: Please select what kind of key you want: (1) ...
3
votes
1answer
48 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 ...
0
votes
0answers
5 views

How can I convert 128-bit AES encryption key to a string using Python? [migrated]

I am trying to decode my 128-bit AES key to string to store it in database. I have tried using Python built-in decode() with ascii and utf-8 codecs but it is not working.
0
votes
0answers
12 views

Symmetric key validity hypothesis? [migrated]

Can I use something like Shannon entropy to determine the suitability of a symmetric key? I found a symmetric key which wasn't generated using a CSPRNG and it had a very low Shannon entropy. I ran an ...
0
votes
0answers
21 views

How do i produce keypairs for my users while implementing json web token

I want to check the integrity of my user information; that the information which my website server receives was indeed sent by them. From what I understand, json web tokens (jwt) is the way to go. I ...
0
votes
1answer
111 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. ...
1
vote
1answer
80 views

Android hardware Keypair Info

Basically I would like to use Android Keystore to sign requests going to a server from an Android phone. My goal is to have a way of verifying the origin of the request. Does Android Keystore offer ...
0
votes
2answers
86 views

Is it OK to use two halves of a key independently?

If I ask AWS Key Management Service for a 64-byte key, is it OK to split it in half and use each half as a separate key? e.g. the first half for encryption and the second for HMAC? I figure that it ...
1
vote
1answer
1k views

How to actually calculate Pairwise Transient Key?

I have following information: PTK-Pairwise Transient Key: A value derived from PMK, Authenicator nonce(Anonce), Supplicant nonce(Snonce), Authenticator Address, Supplicant Address. This is used to ...
0
votes
1answer
85 views

Is User Account Login Related to BitLocker Encryption Key

When I enabled BitLocker on my system-drive, I wasn't asked to select an unlock-method. I didn't have to enter any new passwords/keys. I only selected a few options for the encryption, and the process ...
4
votes
2answers
1k views

Can TPM “Storage Keys” be created outside the TPM?

I am interested in 'adding' preexisting keys to a TPM's storage hierarchy. An example of a desired key hierarchy can be shown as: (SRK)----->(User Storage Key)-------> User Working Key 1 ...
0
votes
1answer
107 views

How does winrar know I typed the right key?

As far as I know WinRar uses the password you type and derives the key from it. But how exactly does it check if the key I typed is correct? What I think is that it compares your guess with the right ...
0
votes
1answer
257 views

Where to locate my private key to SSH?

In my understanding, to ssh login to my server, I need a private key: However, the key I get when generating seems to be a public key: Do you know where to locate my private key? Manually ...
22
votes
6answers
5k views

Alternatives to HTML's deprecated <keygen> for client certs?

The keygen tag is used to make browsers generate private keys and POST the resulting CSR to the server, which can then issue a certificate. It's now been deprecated, for rather stupid reasons but that'...
35
votes
6answers
30k views

What does key signing mean?

What exactly does the "key signing" mean? So for example I have a private/public GPG key so that people could send me encrypted e-mail, because they know my public key. But: what does key signing ...
4
votes
2answers
4k views

Rotating encryption keys - how does it work?

I haven't found a duplicate which explains with sufficient clarity how does the process of rotating encryption keys work in simple layman terms. I know how private/public key cryptography works, I ...
0
votes
1answer
113 views

Is tails needed to securely generate a PGP key on raspberry Pi?

I understand that usually one should use Tails on a trusted machine to generate PGP keys. However, I find it difficult to trust a machine with an Intel CPU, many wireless interfaces, a hard disk that ...
0
votes
2answers
87 views

Recreating the Half Coins of Jin-Qua [closed]

In the Asian Saga series by James Clavell, the Struan family gave away the half-coins of Jin-qua: in exchange for a desperately needed loan, the pirate Dirk Struan received 4 halves of 4 coins. The ...
0
votes
0answers
24 views

Key Pair permission on Windows 2019

I generated a key pair on Windows Server 2019 using the native ssh-keygen located in System32\OpenSSH. Now I think the permissions of the private key are somewhat worrying... Is it expected to have ...
0
votes
1answer
638 views

Key Encryption / Obfuscation

I got a GUI Program, which loads the Logic from a webserver if the entered License Key is valid. The actual connection string I hexed and xor'd with a secret key. (which is unfortunately static) The ...
2
votes
1answer
89 views

Does Docker affect the quality of cryptographic operations?

Is running cryptographic operations (encryption / decryption / signing / verifying / key-exchange / key-generation) in a Docker container affecting the quality of the crypto or entropy? If it does ...
2
votes
0answers
47 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 ...
1
vote
2answers
84 views

How do I program a function to generate a secure Block Cipher Encryption-Key?

I am currently studying the most widely known encryption algorithms and methodologies. For practice purposes, I want to implement everything from ECB to RSA as some kind of a C crypto library. How ...
0
votes
1answer
194 views

Using the user's GUID-id as a salt for Rfc2898DeriveBytes

I use the Rfc2898DeriveBytes for creating an AES key for protecting the user's data. For the salt value I would like to use the user's id, which is a guid. My understanding is, that the only drawback ...
2
votes
2answers
163 views

When gpg encrypt is called from the command line, how is a key chosen to do the encryption?

I am using GnuPG. When gpg encrypt is called from the command line, how is a key chosen to do the encryption? It appears to me that -r, or --recipient, supplies a user id and that is the simple answer....
2
votes
1answer
86 views

Reason to generate encryption keypair server side rather than on device?

I want my native applications (android/ios) to have a keypair (RSA or ECIES) so that certain data on requests to my API can be encrypted. I want each client to have a unique keypair. The device will ...
0
votes
2answers
479 views

Server-side encryption mechanism (Nextcloud)

I've been looking around how server-side encryption works. Thanks to the nextcloud doc I understand the implementation. Basically, when you first log in a key pair is created, and the private key ...
0
votes
1answer
47 views

Deriving a key with PBKDF2 from RFC1751 output

I am building a system that at some point requires a 256 bit key AES key. I used to feed passphrases through PBKDF2 to derive a key, but then I decided to generate random passwords of 12 words ...
0
votes
3answers
349 views

Prevent finding key in C++ application binary

I need to store a key (symmetric-key cryptography) within my C++ application binary (based on OpenCV) so that the key as unidentifiable as possible. Can someone help me choose the key so that is ...
0
votes
1answer
68 views

Updating Sender-Keys and Key-Management

This question is related to an earlier question I had: Encryption on Mobile Devices - Multiparty Encryption - Key Management My situation: I have many mobile devices that want to send sensitive ...
162
votes
8answers
95k views

Best Practice: ”separate ssh-key per host and user“ vs. ”one ssh-key for all hosts“

Is it better to create a separate SSH key for each host and user or just using the id_rsa key for all host to authenticate? Could one id_rsa be a malpractice for the privacy/anonymity policies? ...
2
votes
1answer
145 views

Is sha256 a good function to derive 256 bit keys from a secret of sufficient length and entropy?

Assuming I have a secret key of sufficient length and entropy (I get to decide the length and have a good random source). I would like to generate 256 length keys by hashing the root key with the ...
2
votes
1answer
125 views

Were software “CD key” schemes backdoored or simply misdesigned?

Back in the day, retail software was shipped on physical CDs that often had a printed "CD key" label affixed. The (usually alphanumeric) key on the label was unique to that particular copy of the ...
1
vote
2answers
1k views

Which keystore type is good for java / Tomcat based applications

The application is based on Java and Tomcat server. Which type of keystore is better ? does JKS or PCKS12 ? I understand JDK keytool by default creates JSK type then for which uses-cases one should ...
3
votes
2answers
143 views

What is the difference between host and client ssh key generation?

Having read the ssh-keygen man page, i saw the '-h' flag and the following: ssh-keygen supports two types of certificates: user and host. User certificates authenticate users to servers, whereas ...
32
votes
1answer
18k views

JSON Web Tokens - How to securely store the key?

I was building a RESTful Web Service when I came across JSON Web Tokens as an alternative to traditional cookies for authentication. The conceptual core of this method is that the server is the only ...
-2
votes
3answers
261 views

Is this adaptation of using a One Time Pad safe?

For example, lets say there are two people named, Bob, and Jim. Bob wants to send Jim a long secret message, and he decides to use a OTP to encrypt his message. Both Bob and Jim know a secret ...
0
votes
1answer
63 views

Is it a bad idea to share a private key generated from a self-signed root CA?

Pardon if this is a noob question. I'm writing an authorization function to determine if a REST API request should be allowed to proceed or not. It is using a standard JWT passed in the Authorization: ...
2
votes
1answer
203 views

Why is validating the integrity of the plaintext necessary in addition to validating the integrity of the cipher text?

Reading the iOS Security Guide's description of the iMessage encryption protocol I'm trying to figure out why they included a mechanism for verifying the integrity of the plaintext as well as ...
0
votes
0answers
76 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 ...
8
votes
1answer
901 views

Preparing to change over to new GPG-key - what to do with my old ones?

I've just created a new off-line GPG-key with a sign/certify master-key and two sub-keys - one for signing and one for encrypting. 5 yr expiration for the master, 2 yr for the subs. My master-key got ...
15
votes
2answers
559 views

What research suggests that user's mouse movements are (not) sufficiently unpredictable for secret key generation?

I have not been able to find any credible source which tried to prove or disprove the randomness of mouse movements. A Google Scholar search for "mouse movement entropy" gives surprisingly few ...
0
votes
0answers
800 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 ...
6
votes
2answers
4k views

Do you need more than 128-bit entropy?

UUID uses 128-bit numbers. Currently it is not feasible to randomly produce two UUIDs that are the same. Does that mean 128 bits of entropy is suitable for all cryptographic operations? I would ...
2
votes
2answers
3k views

How to generate the most secure private key? [closed]

I need to generate the most secure private key. Usually I use a command: openssl genrsa -des3 -out mykey.key 2048 Is triple DES secure enough? Is 2048 large enough? Are there any other ways to ...
13
votes
3answers
2k views

How many iterations of Rabin-Miller should be used to generate cryptographic safe primes?

I am generating a 2048-bit safe prime for a Diffie-Hellman-type key, p such that p and (p-1)/2 are both prime. How few iterations of Rabin-Miller can I use on both p and (p-1)/2 and still be ...
0
votes
2answers
188 views

RSA generating private and public keys

I'm trying to implement RSA encryption in PHP. I'm stuck at generating the public and private keys. I have P = 61, Q = 53, MOD = P * Q = 3233, N = (Q - 1) * (P - 1) = 3120. How do I chose the value ...
1
vote
0answers
148 views

How do I reduce the vulnerability of the OpenStack SSH key generation process? [closed]

I found two places that describe OpenStack SSH keys, but nothing seems to say whether or not they're generated on VMs. Generating these on the VMs could lead to problems, since VM images are often ...

1
2 3 4 5 6