Skip to content

Instantly share code, notes, and snippets.

View pyke369's full-sized avatar

Pierre-Yves Kerembellec pyke369

View GitHub Profile
@pyke369
pyke369 / ahs-extractor.go
Created September 16, 2025 11:50
HPE iLO AHS archive extractor
package main
import (
"bufio"
"bytes"
"compress/gzip"
"encoding/binary"
"fmt"
"io"
"os"
@pyke369
pyke369 / go.go
Last active November 9, 2024 17:16
Basic URL shortener in Golang
package main
// -- start service ---
// $ env GOGO_LISTEN='*:8000' GOGO_ALIASES=aliases.json GOGO_BACKUP=true GOGO_KEY=my-secret-key go run go.go
// --- manage aliases ---
// $ curl -H 'Authorization: Key my-secret-key' -X PATCH http://localhost:8000/.well-known/gogo -d '{ "sib":"https://www.stream-in-box.com", "goo":"https://www.google.com" }'
// {"created":["sib","goo"],"deleted":[],"modified":[]}
//
// $ cat aliases.json
@pyke369
pyke369 / hlsfetch.go
Created October 14, 2022 15:49
hlsfetch parallelized downloader
package main
import (
"fmt"
"io/ioutil"
"net/http"
"os"
"regexp"
"strconv"
"strings"
@pyke369
pyke369 / dnsblast.go
Last active September 23, 2024 16:29
package main
import (
"encoding/binary"
"encoding/hex"
"flag"
"fmt"
"math"
"math/rand"
"net"
@pyke369
pyke369 / gotp.go
Last active September 23, 2024 16:32
gotp
// -- build ---
// native go build gotp.go
// ARM 32bits GOOS=linux GOARCH=arm go build gotp.go
// MacOS 64bits GOOS=darwin GOARCH=amd64 go build gotp.go
// -- usage --
// gotp <login> <password> <base32-otp-secret> <write-mode> <auth-file-path>
// gotp j.doe Pn76sk 3HPLQ9GT5TKB3 - /tmp/auth.txt
// -- OpenVPN configuration file --