This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@never_cache | |
def caesar_decrypt(request): | |
def caesar_shift(crypt_text): | |
table = string.maketrans( | |
string.ascii_lowercase, | |
string.ascii_lowercase[13:]+string.ascii_lowercase[:13]) | |
return string.translate(crypt_text.encode(errors="ignore").lower(), table) | |
if request.method == 'POST': |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Tell the kernel you want to use this machine as an IP V4 gateway | |
echo 1 > /proc/sys/net/ipv4/ip_forward | |
# Set up variables for the network interfaces | |
lan_interface=eth0 | |
internet_interface=eth1 | |
# Ports you want your users to connect directly to on the internet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
("(IT||I.T||ICT||I.C.T) manager"||"(system||systems) (manager||administrator)"||"(python||django) (programmer||programer||developer)") site:kenyanjobs.blogspot.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vendor: Dell Inc. | |
Version: 1.5.3 | |
Release Date: 03/12/2013 | |
BIOS Revision: 1.5 | |
CPU information | |
Machine class: amd64 | |
CPU Model: Intel(R) Xeon(R) CPU E5-2640 0 @ 2.50GHz | |
No. of Cores: 12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Squid should be intercepting on port 2600 | |
# A cachaing dns server should be running on this box, with squid and clients all resolving through it. | |
# FreeBSD 9.2 RELEASE + Squid 3.3.9 from ports | |
# Timothy Makobu, 2013 | |
# Variables | |
admin_if = "igb0" | |
external_if = "igb1" | |
intraservices = "{ 22, 2600, 53 }" | |
forward_ports = "{ 443, 465, 6667, 22, 587, 5938, 2083, 2082, 2095, 2096, 5242, 4244, 5243, 9785 }" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from bs4 import BeautifulSoup | |
from num2words import num2words | |
import time | |
import subprocess | |
import re | |
import random | |
maxlen = 31 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#changelist-filter { | |
position: absolute; | |
top: 0; | |
right: 0; | |
z-index: 1000; | |
width: 160px; | |
height: 100%; | |
border-left: 1px solid #ddd; | |
background: #efefef; | |
margin: 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Code to send SMS via the Sematime API | |
# API Doc: https://s3.amazonaws.com/api.sematime.com/Sematime+API+Docs.pdf | |
import json | |
import requests | |
def send_message(recipients, message): | |
user_id = "" # your user id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Combat Computer Vision Syndrome using the 20-20-20 rule | |
# Every 20 minutes, spend 20 seconds looking at something 20 feet away, minimum. | |
# https://www.vsp.com/computer-vision-syndrome.html | |
# @timkofu, 2016 | |
import subprocess | |
import time | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Keeps heroku free dyno from sleeping | |
# Runs from cron every 29 minutes | |
import requests | |
import gevent | |
from gevent import monkey | |
monkey.patch_all() | |
OlderNewer