This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Change these variables as necessary. | |
main_package_path = ./cmd/example | |
binary_name = example | |
# ==================================================================================== # | |
# HELPERS | |
# ==================================================================================== # | |
## help: print this help message | |
.PHONY: help |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Utility class to read encrypted PEM files and generate a SSL Socket Factory based on the provided certificates. | |
* This utility also support an option to enable and disable server hostname verification. | |
* | |
* Note: Java use jks (Java KeyStore) format, but openssl usual use pem format. We can convert it by keytool (jdk build-in tool), or use | |
* BouncyCastle library to handle pem. | |
* | |
* The original code is by Sharon Asher (link below). I have modified it to use a newer version of the BouncyCastle Library (v1.68) | |
* Add below dependencies to work with this util. | |
* org.bouncycastle:bcpkix-jdk15on:1.68 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Go to the Postman app download page at https://www.getpostman.com/apps. You can choose the os version from the drop-down. x64 for 64 bit Operating System and x84 for the 32 bit based Linux | |
2. Open the terminal and go to the directory where you have downloaded the tar file. If you have downloaded on the Downloads folder | |
cd ~/Downloads/ | |
3. Run the following commands, | |
sudo rm -rf /opt/Postman/ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.*; | |
import java.nio.file.*; | |
import java.security.*; | |
import java.security.cert.*; | |
import javax.net.ssl.*; | |
import org.bouncycastle.jce.provider.*; | |
import org.bouncycastle.openssl.*; | |
public class SslUtil |