Skip to content

Instantly share code, notes, and snippets.

sigmunau / example-site.conf
Last active January 17, 2017 08:52
Example site configuration using apache mod_auth_openidc and dataporten
DocumentRoot /var/www/html
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
# OpenID Connect metadata for dataporten.
OIDCSSLValidateServer On
fab -H -- uname -r > /dev/null 2> /dev/null 7,19s user 0,01s system 96% cpu 7,482 total
fab -H -- uname -r > /dev/null 2> /dev/null 7,24s user 0,01s system 96% cpu 7,529 total
fab -H -- uname -r > /dev/null 2> /dev/null 7,21s user 0,02s system 96% cpu 7,506 total
fab -H -- uname -r > /dev/null 2> /dev/null 1,17s user 0,02s system 82% cpu 1,440 total
fab -H -- uname -r > /dev/null 2> /dev/null 1,16s user 0,02s system 80% cpu 1,468 total
def match_ip_address(cert, ip_address):
"""Verify that *cert* (in decoded format as returned by
SSLSocket.getpeercert()) matches the *ip_address*. According to RFC 6125
CertificateError is raised on failure. On success, the function
returns nothing.
if not cert:
raise ValueError("empty or no certificate")
sigmunau / _gem
Last active December 18, 2015 18:09 — forked from alexvollmer/_gem
#compdef gem gem1.9
gem_general_flags=("(-h --help)"{-h,--help}"[Get help on this command]"
"(-V --verbose)"{-V,--verbose}"[Set the verbose level of output]"
"(-q --quiet)"{-q,--quiet}"[Silence commands]"
"--config-file[Use this config file instead of default]:file:_files"
"--backtrace[Show stack backtrace on errors]"
"--debug[Turn on Ruby debugging]"