Author Archives: smike19

How to Get Subject Alternative Names for a SSL/TLS Certificate

CN (Common Name) identifies a single domain in an SSL/TLS certificate. It could be name with wildcard symbols. While SAN (Subject Alternative Name) can provide list multiple different domain names and subdomains on one certificate. Modern web browsers can read and utilize the Subject Alternative Name. .Net and openssl API can also extract SAN information… Read More »

Installing Microsoft Powershell on Ubuntu 24.04

I previously installed Powershell on CentOS. That time for Ubuntu I started from Microsoft repositories too and began to add Microsoft repository as well. I checked Microsoft repositories for Ubuntu. First I download prod.list info /etc/apt/sources.d directory: $ cd /etc/apt/sources.list.d/ $ sudo curl -O https://packages.microsoft.com/config/ubuntu/24.04/prod.list The prod.list looks like: $ cat /etc/apt/sources.list.d/prod.list deb [arch=amd64,arm64,armhf signed-by=/usr/share/keyrings/microsoft-prod.gpg]… Read More »

Split file to pieces in Linux and join it again

More than 10 years ago I created binary editor for Windows called xedit. I mentioned this tool already twice here. To find these posts put in search text box xedit and click on Search button. This tool does a lot of useful things with files and I still utilize it sometime. It is still available… Read More »

Run Linux file processing commands in Windows

Sometime it is necessary to compress or expand gz or tar files, print the sequences of printable characters from binary files or something similar. There are terminal commands which do such operations in Linux but in Windows usually it is necessary to download in install extra tool. However it is Windows Subsystem for Linux permits… Read More »

Simulate SIGPIPE signal

SIGPIPE signal happens on attempt to write to closed or broken pipe. In this situation process is terminated and returns error code 141. It is possible to simulate this signal by creating not correct output redirection. Example below shows that tee command output to stdout and file a.a and returns 0: # echo -n ladydebug.com… Read More »

snmp++v3 crashes after version upgrade.

SNMP++v3.x is free open source c++ API library which may be used in different operating systems such as Linux, FreeBSD, Mac OS X, Solaris and Windows. Initially it was developed by Hewlett-Packard, but currently maintained by AGENTPP. I started to use it beginning from version snmp++-3.2.17 and time by time upgrading to newer one. Usually… Read More »

Windows Subsystem for Linux. Accessing files.

Linux distributions uses the Filesystem Hierarchy Standard (FHS) which defines the universal directory structure (like home, usr, bin, tmp and so on) and directory contents. To access to Windows c: drive from install WSL Linux distribution use /mnt/c directory. Let us create c:\Temp\ubuntu.txt file from WSL ubuntu 24.04 distribution: C:\>wsl -d Ubuntu-24.04 smoke29@MSI:/mnt/c$ sudo echo… Read More »

CGO example to get openssl cipher list

This post is related to “How to get openssl cipher list programmatically” post. That post contains example written in C, current post presents example in Go which duplicates sequence of openssl API calls used by previous post. The Go example uses CGO package that enables interaction with C code of openssl shared libraries. package main… Read More »