This guide explains how to set up Kerberos authentication for:
- SSH access to a server,
- HTTP access to a service.
It assumes you're running Active Directory and Debian servers.
#lang racket | |
;;; | |
;;; Author: Bahman Movaqar <Bahman AT BahmanM.com> | |
;;; | |
(require net/url) | |
(require sxml) | |
(require net/uri-codec) | |
(require net/http-client) | |
(require (planet neil/html-parsing)) | |
(require net/cookies) |
from ijson import common | |
from ijson.backends import YAJLImportError | |
from cffi import FFI | |
ffi = FFI() | |
ffi.cdef(""" | |
typedef void * (*yajl_malloc_func)(void *ctx, size_t sz); | |
typedef void (*yajl_free_func)(void *ctx, void * ptr); | |
typedef void * (*yajl_realloc_func)(void *ctx, void * ptr, size_t sz); |
""" | |
client.py - AsyncIO Server using StreamReader and StreamWriter | |
This will create 200 client connections to a server running server.py | |
It will handshake and run similar to this: | |
Server: HELLO | |
Client: WORLD |
import time | |
class EventfulDict(dict): | |
"""Eventful dictionary""" | |
def __init__(self, *args, **kwargs): | |
"""Sleep is an optional float that allows you to tell the | |
dictionary to hang for the given amount of seconds on each | |
event. This is usefull for animations.""" | |
self._sleep = kwargs.get('sleep', 0.0) |
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
/* | |
* MCrypt API available online: | |
* http://linux.die.net/man/3/mcrypt | |
*/ | |
#include <mcrypt.h> |
#!/bin/bash | |
if (( $# < 1 )) | |
then | |
echo "Usage: $0 username" | |
exit 1 | |
fi | |
username="$1" | |
json_left='{"input01":{"Input":"GmailAddress","GmailAddress":"' |
@font-face { | |
font-family: "Inconsolata"; | |
font-style: normal; | |
font-weight: normal; | |
src: local("Inconsolata"), url("http://themes.googleusercontent.com/static/fonts/inconsolata/v3/BjAYBlHtW3CJxDcjzrnZCIbN6UDyHWBl620a-IRfuBk.woff") format("woff"); | |
} |
if (typeof window.localStorage == 'undefined' || typeof window.sessionStorage == 'undefined') (function () { | |
var Storage = function (type) { | |
function createCookie(name, value, days) { | |
var date, expires; | |
if (days) { | |
date = new Date(); | |
date.setTime(date.getTime()+(days*24*60*60*1000)); | |
expires = "; expires="+date.toGMTString(); |