Skip to content

Instantly share code, notes, and snippets.

View kala13x's full-sized avatar

Sandro Kalatozishvili kala13x

View GitHub Profile
@kala13x
kala13x / xssl.hpp
Last active February 18, 2021 11:06
OpenSSL client/server implementation example for C++
/*
* xssl.hpp
*
* Copyleft (C) 2020 Sun Dro ([email protected])
* OpenSSL server/client implementation example for C++
*/
#ifndef __CXXUTILS_XSSL_H__
#define __CXXUTILS_XSSL_H__
@kala13x
kala13x / xjson.c
Last active February 1, 2022 16:18
JSON linter and minify with xutils/xjson
/*!
* @file libxutils/examples/xjson.c
*
* This source is part of "libxutils" project
* 2019-2021 Sun Dro ([email protected])
*
* @brief Parse, lint and minify json using xjson library.
*/
#include <xutils/xstd.h>
@kala13x
kala13x / lagint.c
Last active July 13, 2022 17:45
Lagrange polynomial and coefficient calculations
/*
* lagint.c
* 2019-2020 Sun Dro ([email protected])
*
* Calculate Lagrange interpolated polynomials and
* displays the coefficient of each polynomials
*/
#include <stdio.h>
#include <errno.h>
@kala13x
kala13x / chat_server.cpp
Last active November 26, 2021 21:34
Simple chat server with subscribe pattern
/*
* upwork/singles/chat_server.cpp
*
* 2021 (c) Sun Dro ([email protected])
*
* EPOLL based high performance chat server with subscribe pattern
* Compile: g++ -g -O2 -Wall chat_server.cpp -o chat_server -lpthread
*/
#include <stdio.h>
@kala13x
kala13x / events.c
Created January 7, 2022 21:55
High performance event based non-blocking echo server
/*!
* @file libxutils/examples/events.c
*
* This source is part of "libxutils" project
* 2015-2020 Sun Dro ([email protected])
*
* @brief Implementation of high performance event based non-blocking echo server.
* The xUtils library will use poll() or epoll() depending on the operating system.
*/
@kala13x
kala13x / statcov.c
Created January 26, 2022 13:08
Parse COVID-19 case statistics from https://stopcov.ge/ and display JSON serialized output
/*!
* @file libxutils/examples/statcov.c
*
* 2020-2021 Sun Dro ([email protected])
*
* @brief Parse and print COVID-19 case
* statistics from https://stopcov.ge/
*/
#include <xutils/xstd.h>
@kala13x
kala13x / xhttp.c
Created February 1, 2022 16:17
HTTP Client Tool - Send costum HTTP request, analyze headers, download content, etc.
/*!
* @file libxutils/examples/xhttp.c
*
* This source is part of "libxutils" project
* 2015-2020 Sun Dro ([email protected])
*
* @brief Example file for working with the HTTP request/responses.
* Send costum HTTP request, analyze headers, download content, etc.
*/
@kala13x
kala13x / xtop.c
Last active March 13, 2022 09:03
Advanced system monitor with network, memory and CPU statistics in one window
/*!
* @file libxutils/examples/xtop.c
*
* This source is part of "libxutils" project
* 2015-2022 Sun Dro ([email protected])
*
* @brief Implementation of advanced system monitor based on the xUtils.
* Collect and monitor network, memory and CPU statistics in one window.
*/
@kala13x
kala13x / pcap2ts.c
Last active June 27, 2022 14:33
Extract MPEGTS payload from PCAP file
/*!
* @file pcap2ts.c
*
* 2015-2022 Sun Dro ([email protected])
*
* @brief Extract MPEGTS payload from PCAP file.
* Usage: pcap2ts <input> <output> <verbose>
* Example: pcap2ts dump.pcap payload.ts 1
*
* Compile command:
@kala13x
kala13x / xdb.c
Last active February 3, 2026 18:23
XDB File Reader for CLI
/*!
* @file xdb/xdb.c
*
* 2015-2026 Sun Dro ([email protected])
*
* @brief Implementation of the XDB file parser
* Using: https://github.com/kala13x/libxutils
*/
#include <xutils/xstd.h>