Skip to content

Instantly share code, notes, and snippets.

Avatar
🌴
On vacation

Nicolas Mora babelouest

🌴
On vacation
View GitHub Profile
@babelouest
babelouest / VERSION
Last active June 5, 2022 21:41
Simple rainloop plugin to login to the webmail using oidc server, dovecot master password and apache module auth_openidc - Download those files in a directory named oidc-master-password-login/
View cert-extension.sh
#!/bin/sh
certtool --generate-privkey --outfile packed.key --sec-param High
certtool --generate-request --load-privkey packed.key --outfile packed.csr --template template-ca.cfg
certtool --generate-self-signed --load-privkey packed.key --outfile packed.crt --template template-ca.cfg
certtool --generate-privkey --outfile client-p-v.key --key-type=ecdsa --sec-param High
certtool --generate-request --load-privkey client-p-v.key --outfile client-p-v.csr --template template-client.cfg
certtool --generate-certificate --load-request client-p-v.csr --load-ca-certificate packed.crt --load-ca-privkey packed.key --outfile client-p-v.crt --template template-client.cfg
@babelouest
babelouest / hmac-secret-demo.html
Last active January 3, 2023 02:14
might be usable in a foreseen future (this was written in 2019), but hmac-secret still isn't available in the browser I know of
View hmac-secret-demo.html
<!doctype html>
<html lang="en">
<head>
<!--
inspired by Mozilla Webauthn documentation: https://developer.mozilla.org/en-US/docs/Web/API/Web_Authentication_API
copyright: 2019 Nicolas Mora <nicolas@babelouest.org>
license: MIT
-->
<title>Hmac-Secret webauthn Extension</title>
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/cbor-js-unofficial@0.1.0-a4/cbor.min.js"></script>
View gnutls_generate_pkcs12.c
/**
*
* gnutls_generate_pkcs12.c
*
* Generate a new RSA key
* Generate the associated certificate
* Sign the certificate with the issuer key and certificate
* Create the PKCS#12 structure and exports it to the file out.p12 protected with the password PASSWORD
*
* License: MIT
View resize-libav.c
/**
*
* resize-libav
*
* Use libav to resize an image using its swscale functions, sample code
*
* Copyright 2018 - Nicolas Mora <mail@babelouest.org>
* Copyright (c) 2013-2017 Andreas Unterweger
*
* This program is free software; you can redistribute it and/or