For excessively paranoid client authentication.
Updated Apr 5 2019:
because this is a gist from 2011 that people stumble into and maybe you should AES instead of 3DES in the year of our lord 2019.
some other notes:
from flask import Flask, request, session, url_for, redirect, \ | |
render_template, abort, g, flash | |
from werkzeug.contrib.sessions import Session, SessionStore | |
from cPickle import HIGHEST_PROTOCOL | |
from random import random | |
from flask import json | |
class MemcachedSessionStore(SessionStore): | |
def __init__(self, servers=None, key_prefix=None, default_timeout=300): |
# -*- coding: utf-8 -*- | |
""" | |
Created on 09/11/2011 | |
@author: Carlo Pires <carlopires@gmail.com> | |
""" | |
import tnetstring | |
from werkzeug.contrib.sessions import SessionStore | |
SESSION_TIMEOUT = 60*60*24*7 # 7 weeks in seconds |
TL;DR
Install Postgres 9.6, and then:
sudo pg_dropcluster 9.6 main --stop
sudo pg_upgradecluster 9.5 main
sudo pg_dropcluster 9.5 main
*update: TBC, but this new might affect how easy it is to use this technique past August 2024: Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August
This gist, based in part on a gist by Brian Hartvigsen, allows you to export from Authy your TOTP tokens you have stored there.
Those can be "standard" 6-digits / 30 secs tokens, or Authy's own version, the 7-digits / 10 secs tokens.
Jenkins.instance.queue.items.findAll { !it.task.name.contains("Extenda") }.each { | |
println "Cancel ${it.task.name}" | |
Jenkins.instance.queue.cancel(it.task) | |
} | |
Jenkins.instance.items.each { | |
stopJobs(it) | |
} | |
def stopJobs(job) { | |
if (job in jenkins.branch.OrganizationFolder) { | |
// Git behaves well so no need to traverse it. |