Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

OpenSSL is an open source implementation of the SSL and TLS protocols. Questions about how to use the OpenSSL tools and libraries are usually better asked at Stack Overflow or Super User.

-1
votes
0answers
18 views

Implementation of EVP AES 128 CTR using openssl library

How should I provide counter value in order to test my algorithm with the standard test vectors given in IETF Tools? Code snippet: ...
3
votes
3answers
337 views

What is different below two Ciphersuites?

I have two questions; I need an explanation for the differences of below two cipher suites. How do they work with SSL/TLS protocol? (my main concern first one doesn't have '...
-1
votes
0answers
32 views

Trying to understand how openssl calculates IV and key from passphrase

Once I generate the encrypted private key, public key and ca certifcates from openssl for radius server. With sha256-pkdf2 and 3des I put these files in ubuntu system for eapol communication. I am ...
0
votes
0answers
46 views

Can't sign with DSA [migrated]

A DSA key is created with: ...
3
votes
1answer
186 views

Why can't decrypt with OpenSSL if salt changed (for CBC and ECB)

A file encrypted with OpenSSL (with, for example, AES 256-bit mode CBC) using the Linux command openssl enc -aes-256-cbc -in texte -out encrypted_texte -k password ...
1
vote
1answer
32 views

What is the encoding protocol for passphrase protected RSA private keys?

What is the protocol used to encode an RSA key protected with a passphrase? If I generate an RSA key with ssh-keygen -t rsa -b 4096 and do: ...
0
votes
0answers
18 views

OpenSSL decrypt AES 256bit (base64) encrypted password - wrong final block length [migrated]

I am trying to decrypt aes-256-cdc encoded password using OpenSSL ...
2
votes
1answer
132 views

Is this a good PHP encryption Strategy?

I'm writing a multi-tenant application that interacts with a couple of different APIs on behalf of each customer. Obviously, we need to store private keys for these various different APIs in the ...
1
vote
1answer
85 views
2
votes
1answer
117 views

X25519 - why openssl shows 253 bits?

When using ECDHE with Curve25519 with openssl: Server Temp Key: X25519, 253 bits I thought when we use X25519, it use 256 bit key. Why openssl shows the server temp key as 253 bits?
3
votes
0answers
43 views

How to see Diffie Hellman private key used during negotiation? [closed]

I used OpenSSL s_client to connect to a test server. Because OpenSSL generated client side private DH key, I think there will be a way to show the private key or ...
2
votes
1answer
33 views

The “openssl genrsa” command only generates a private key?

The command : openssl genrsa -out RootCA.key 4096 generates a single file named RootCA.key. When I open the file, it only contains the private key. Then ...
1
vote
1answer
46 views

Question about OpenSSL testing for FIPS 186-4 and using BN_generate_prime_ex

I am working on testing my implementation of OpenSSL using the CAVP 186-4 RSA Validation System (RSA2VS). There are tools under openssl-fips-2.0.16/test and I am working on modifying fips_rsagtest.c ...
1
vote
1answer
56 views

Question about using BN_rand() [closed]

I am working on a project and I'm noticing a peculiar behavior that I was hoping someone could tell me if it is correct or not. I have a program that is trying to generate some random numbers using ...
-1
votes
1answer
35 views

I am new to digital certificate 509V3 concept. can some one please clarify the below points [closed]

I am using RSA 2048 with SHA 256 primitive in certificate: How to verify the user certificate n + 1 with Root certificate n? why it is required to perform Certificate chain verification? How to ...
2
votes
1answer
25 views

Does the server signs message body after ssl handshake?

So after SSL handshake the master secret is used to securely transfer data encrypted using symmetric cryptography. My question is simple: after SSL handshake, when the server (for example my bank) ...
0
votes
1answer
82 views

What is the difference between: ecdsap, ecdsak, and ecdsab in the output of “openssl speed”? What do the letters P/K/B refer to?

openssl speed tests the speed of different protocols on your computer: ...
1
vote
3answers
278 views

Differences between DSA and RSA Algorithms

Despite having learned much related to RSA and DSA, I cannot understand their differences. Can anyone tell me at least 4-5 differences between these algorithms? I have just used them for two-factor ...
1
vote
1answer
57 views

Clarifications regarding ciphers and Nmap scan

I'm running the below Nmap command to test the strength of the cipher suites I have used in my host nmap -sV --script ssl-enum-ciphers -p 443 <host> The ...
0
votes
2answers
381 views

Appropriate key for AES 256 GCM

I am updating a system that has Rails' OpenSSL on one side and Python's cryptography.io on the other. The Rails side has to generate keys for the AES-256-GCM and here are two methods that appear to ...
2
votes
1answer
84 views

Do aes_256_gcm IVs just need to be unique for that key?

I'm using GCM (via openssl's EVP_EncryptInit_ex(ctx, EVP_aes_256_gcm(), NULL, NULL, NULL))). The IV's default length is 12 bytes. It says that the IV must be ...
1
vote
0answers
34 views

Benefits of using SSL certificate over a raw key pair for non-browser use?

For applications not involving CA signed certificates – or web browsers for that matter – it would seem to be easier to use a raw key pair if possible, rather than deal with potential formatting ...
1
vote
1answer
493 views

symmetric AES encryption with php produces different result than openssl MacOX

I need to make a simple very basic encryption with AES 128 ECB mode. The idea is to generate a cryptogram, code it in base64 and then decipher that text from a web service in php to process its ...
1
vote
0answers
106 views

openssl command line equivalent of AESWrap? (defined in RFC3394; use in AmazonS3 Client Side Encryption of datakey wrapping) [closed]

when dealing with S3 Client Side Encryption, it's using "AESWrap" (defined in rfc3394) algorithm to encrypt the data-key; I'm trying to play with openssl command line to see if it's possible decrypt ...
0
votes
1answer
48 views

Link between openssl 'req' command and 'unable to get local issuer certificate'?

I was using the following command to build a self-signed certificate after creating a private key: ...
2
votes
1answer
61 views

CAs are pre-loaded on the system, but how is it able to get intermediate certs?

I have the following X509 certificate: ...
0
votes
1answer
285 views

What is the Peer Signing digest on an OpenSSL s_client connection?

For a little background, I am trying resolve an issue with an ISAM (reverse proxy) appliance not being able to connect to a server due to it failing to complete a TLS connection. A server that is ...
0
votes
1answer
271 views

Discrepancy between 3DES in OpenSSL and PyDES [closed]

I'm trying to encrypt some data using triple DES ECB, but I get a discrepancy between OpenSSL and the pyDES library I'm using. When trying to get a KCV value, I'm using a file consisting of 8 bytes ...
0
votes
0answers
44 views

Using OpenSSL to emulate LTO 4 tape encryption

I have a mix of LTO 4 and LTO 3 tapes I would like to encrypt data on to. LTO 4 has built in encryption - load they key into the drive, and it handles the AES-256-GCM encyption transparently. LTO 3 ...
0
votes
1answer
205 views

Best method to achieve authenticated encryption with openssl

Problem I want to send a plaintext document between from myself to someone else over an untrusted link. I want to firstly stop third parties from reading the document, I want the receiver to be able ...
0
votes
1answer
273 views

Which cipher to use with openssl for shortest output?

I'd like to encrypt my 12-24 words seed for my bitcoin wallet with openssl command line tool to be able to have it with me on paper without the risk that somebody could use it Which cipher should I ...
1
vote
1answer
133 views

How to select elements randomly from a multiplicative group Zn*

I am working on a problem in which I have two large safe primes say p and q randomly selected each of 512 bits. I have generated ...
0
votes
1answer
2k views

Proper implementation of AES-256-GCM with PHP OpenSSL [closed]

I am really lost in this subject, I find it hard to get any reliable documentation on the subject that is a bit friendly for beginners like me. So I apologize in advance if this question would sound ...
1
vote
1answer
194 views

How to sign a CRL file if I have offline keys?

I am generating a CA for internal use. When generating a CA, the best practice I have observed is to keep the root CA offline and emit an intermediate CA certificate that will in turn emit the end-...
-3
votes
1answer
54 views

How to find out whether RNG is reliable or not , when we generate RSA keys from OpenSsh?

I just want to check whether the entropy supplied is good enough for key generation or not .
0
votes
1answer
264 views

RSA Key Differences (OpenSSL CLI vs. OpenSSL/ssl.h C function)

So, I am sitting here trying to figure out what is happening and why two keys are different in such a vast manner. I've created two key pairs, one key pair with the OpenSSL CLI commands on an Ubuntu ...
0
votes
1answer
267 views

how to validate cert when signed cert has authority key id but signing cert doesn't?

Say I have the following signing cert: ...
1
vote
1answer
167 views

OpenSSL - creating random elliptic curve and measuring performance

I want to generate random elliptic curves (over $\mathbb F_p$ and $\mathbb F_{2^m}$) using OpenSSL, that's my task. At first curves over $\mathbb F_p$. Now I am able to generate prime $p$, $a$ and $b$...
1
vote
1answer
136 views

Obtain Information about hash algorithm from ECDSA public key

I have an ECDSA Public Key in DER Format. I viewed the file in an ASN1 Editor and there's the OID 1.2.840.10045.1.1 whose superior (...
1
vote
1answer
315 views

How does HTTPS transfer the symmetric key?

How is the server's public key used to encrypt the symmetric key in a way so that only the sever's private key can decrypt the cipher? The client uses the server’s public key to encrypt the ...
-1
votes
2answers
2k views

Decrypt AES key with RSA public key

So here's my problem: I have 3 files. One is ciphertext.enc, which is a text encrypted using AES 256. The second one is ...
0
votes
1answer
185 views

Changing password hash and iv on (successful) user login

I've implemented a system for my login page (with php) that will update the password hash and initialization vector (for openssl) on each login. So essentially, every time the user successfully logs ...
0
votes
2answers
3k views

How to encrypt a string using RSA public key only? [closed]

I have been given the following public RSA key: ...
5
votes
2answers
355 views

Security of non-standard use for AES-256-CTR?

I have a string secret that I would like to encrypt for storage in a Yubikey's second slot. These slots can be configured to store up to 38 characters that are later "typed" by the USB device acting ...
2
votes
1answer
1k views

Decrypting encrypted SAML attributes with openssl

I am trying to decrypt encrypted attributes in a SAMLResponse (being sent to the SP) to debug a sample application. Given the following attributes in the ...
4
votes
2answers
1k views

Why does openssl derive IVs from a password?

From https://wiki.openssl.org/index.php/Manual:Enc(1): When a password is being specified using one of the other options, the IV is generated from this password. Why does OpenSSL do this? My ...
1
vote
1answer
65 views

Can we use higher strength SHA along with lower strength RSA key in SSL?

I have noticed when the RSA public key is 2048 bit, SHA-256 bit used for signatures. When the key is 3072 bit, SHA-384 bit used. When the key is 4096 bit, SHA-512 bit used. I have tried the ...
-1
votes
1answer
1k views

Is there a complete list of Signature Algorithm names?

I need to analyze the output of rbsec's sslscan which reports a server's SSL/TLS configuration as reported by OpenSSL. I'm interested in the Certificate's Signature Algorithm in particular, and I was ...
2
votes
1answer
305 views

Is the openssl implementation of ECDH missing something?

From the OpenSSL Wiki: Also note that the derived shared secret is not suitable for use directly as a shared key. Typically the shared secret is passed through some hash function first in order to ...
3
votes
1answer
192 views

TLS 1.3: the key_share in a ClientHello after a HelloRetryRequest

In TLS 1.3 draft-21, if there is a ClientHello with a key_share, say, $(G_1, g^x)$, the server can send a ...