security enabled verified low v1.0.0

openssl

Comprehensive cryptographic toolkit for SSL/TLS, certificate management, encryption, hashing, and key generation.

📋 Live Preview
openssl {action} {algorithm} {input} {output}
๐Ÿ“Ž action ๐Ÿ“Ž algorithm ๐Ÿ“Ž input ๐Ÿ“Ž output
openssl {action} {algorithm} {input} {output}

Sandbox: execFile · Timeout: 60s

Capabilities

security.crypto.hash
security.crypto.encrypt
security.crypto.decrypt
security.crypto.sign
security.crypto.verify
security.crypto.keygen
security.crypto.certificate
security.crypto.csr
security.tls.connect
security.tls.inspect

Artifacts

TypeDescriptionMIMESchemaTrust
security.certificate.pemX.509 certificate (PEM or DER)application/x-pem-file1.0.0verified
security.key.privatePrivate keyapplication/x-pem-file-verified
security.key.publicPublic keyapplication/x-pem-file-verified
security.certificate.csrCertificate Signing Requestapplication/x-pem-file-verified

Contract

Inputs

data.raw

Input data for hashing, encryption, or signing

security.key.private

Private key for signing or decryption

Outputs

data.hashed

Hash or digest output

data.encrypted

Encrypted data

security.certificate.pem

Generated X.509 certificate

Side effects: filesystem_write

Workflow Edges

Produces

data.hasheddata.encryptedsecurity.certificate.pem

Consumes

data.rawsecurity.key.private

Resource Profile

ResourceValue
CPUmedium
Memory32 MB
Networknone
Disk I/Olow

Examples

Generate an RSA private key

openssl genrsa -out private.pem 2048

Generate a self-signed certificate

openssl req -x509 -newkey rsa:4096 -keyout key.pem -out cert.pem -days 365 -nodes

Compute SHA-256 hash of a file

openssl dgst -sha256 file.txt

Encrypt a file with AES-256

openssl enc -aes-256-cbc -salt -in plain.txt -out encrypted.enc

Connect to an HTTPS server and inspect certificate

openssl s_client -connect example.com:443 -showcerts

View certificate details

openssl x509 -in cert.pem -text -noout

Documentation

OpenSSL โ€” Cryptographic Toolkit

OpenSSL is the industry-standard cryptographic library that provides tools for SSL/TLS, certificate management, encryption, and hashing. It's essential for secure communications and data protection.

Certificate Management

Generate Certificate Authority

# Generate CA private key
openssl genrsa -out ca-key.pem 4096

# Generate CA certificate
openssl req -x509 -new -key ca-key.pem -out ca-cert.pem -days 3650

Generate Server Certificate

# Generate server private key
openssl genrsa -out server-key.pem 2048

# Generate CSR
openssl req -new -key server-key.pem -out server.csr

# Sign with CA
openssl x509 -req -in server.csr -CA ca-cert.pem -CAkey ca-key.pem -CAcreateserial -out server-cert.pem -days 365

Encryption & Decryption

# Encrypt a file with password
openssl enc -aes-256-cbc -salt -in secret.txt -out secret.enc -pbkdf2

# Decrypt
openssl enc -d -aes-256-cbc -in secret.enc -out secret.txt -pbkdf2

# Encrypt with key file
openssl rsautl -encrypt -pubin -inkey public.pem -in plain.txt -out encrypted.bin

TLS Connection Testing

# Test HTTPS connection
openssl s_client -connect example.com:443 -servername example.com

# Show certificate chain
openssl s_client -connect example.com:443 -showcerts </dev/null

# Test TLS version support
openssl s_client -tls1_2 -connect example.com:443

Hashing

# Compute hash of a file
openssl dgst -sha256 file.txt
openssl sha256 file.txt

# HMAC
echo -n "data" | openssl dgst -sha256 -hmac "key"

Related Tools

  • certbot โ€” Let's Encrypt certificate automation
  • cfssl โ€” CloudFlare's PKI toolkit
  • easyrsa โ€” Simple CA management

Related Tools

gnutlscertbotcfssleasyrsa

References