Need to setup gpg-agent first, on OSX I use keychain (it also does ssh-agent)
$ brew info keychain
keychain: stable 2.8.5
User-friendly front-end to ssh-agent(1)
https://www.funtoo.org/Keychain
/usr/local/Cellar/keychain/2.8.5 (7 files, 108.5KB) *
--- | |
version: "3.9" | |
services: | |
zookeeper: | |
image: confluentinc/cp-zookeeper:7.2.1 | |
environment: | |
ZOOKEEPER_CLIENT_PORT: 2181 | |
ZOOKEEPER_TICK_TIME: 2000 | |
kafka: |
var https = require('https'), | |
user = process.argv[2], | |
opts = parseOpts(process.argv.slice(3)) | |
request('/users/' + user, function (res) { | |
if (!res.public_repos) { | |
console.log(res.message) | |
return | |
} | |
var pages = Math.ceil(res.public_repos / 100), |
The examples below use the base ssl configuration found here: SSLConfig of the library: SSLContext Kickstart
Java
import java.io.IOException; | |
import java.nio.charset.StandardCharsets; | |
import java.nio.file.Files; | |
import java.nio.file.Path; | |
import java.nio.file.Paths; | |
import java.nio.file.StandardOpenOption; | |
import java.util.ArrayList; | |
import java.util.List; | |
import java.util.stream.Collectors; |
Curl doesn't have support for java keystore file, so therefor the file should be converted to a PEM format. It consists of the following multiple steps:
Press minus + shift + s
and return
to chop/fold long lines!
This cheat sheet came into life when I started working on a tutorial of setting up one way tls and two way tls, which can be found here: GitHub - Mutual TLS SSL
Generate a Java keystore and key pair
keytool -genkeypair -keyalg RSA -keysize 2048 -keystore keystore.jks -alias server -validity 3650