Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
public static class ILogExtentions | |
{ | |
private static readonly log4net.ILog log = | |
log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType); | |
public static void Trace(this ILog log, string message, Exception exception) | |
{ | |
log.Logger.Log(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType, | |
log4net.Core.Level.Trace, message, exception); |
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000
-- udp-client test | |
-- based on code from http://blog.chinaunix.net/uid-27194309-id-3499261.htmlEF | |
local socket = require "socket" | |
local address = "127.0.0.1" | |
local port = 8080 | |
local udp = socket.udp() | |
udp:settimeout(0) | |
udp:setpeername(address, port) |
HTTP/1.1 200 OK | |
Server: MSLC | |
Date: Sun, 28 Dec 2015 08:50:04 GMT | |
Content-Type: text/html; charset=utf-8 | |
Connection: keep-alive | |
Vary: Accept-Encoding | |
Status: 200 OK | |
Cache-Control: no-cache | |
Access-Control-Allow-Origin: * | |
Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type, Accept |
- install the two shellscripts into the appropriate places under /etc/initramfs-tools | |
- run update-initramfs | |
- put "overlay=yes" on the kernel command line | |
- reboot | |
With the overlay in place, the real root is mounted readonly on /ro. | |
Only the root fs is changed, other filesystems are mounted normally. | |
Remove "overlay=yes" (or change it to something other than yes) and reboot to go back to readwrite. | |
(This probably means that you want the commandline config to live somewhere other than on the root fs, e.g. under /boot) |
#!/usr/bin/env lua5.2 | |
-- | |
-- apt install lua5.2 lua-socket | |
-- | |
local socket = require("socket") | |
local udp = assert(socket.udp()) | |
local data | |
udp:settimeout(1) |
#!/usr/bin/env python | |
# Read a Mozilla places JSON-structure from STDIN and create a directory | |
# hierarchy of org-mode files containing bookmarks. | |
# Copyright (c) 2014 Alexey Kutepov a.k.a. rexim | |
# Copyright (c) 2016 Sebastian Reuße | |
# Permission is hereby granted, free of charge, to any person | |
# obtaining a copy of this software and associated documentation files |
// ==UserScript== | |
// @name Spoof screen resolution & color depth | |
// @namespace https://skyzohlabs.be | |
// @version 1.0.5 | |
// @description Spoof the reported window.screen as the most common one so that it can't be used to fingerprint browser. | |
// @author SkyzohKey | |
// @include http://* | |
// @include https://* | |
// @run-at document-end | |
// @grant none |
#! /usr/bin/env python3 | |
""" | |
List all Firefox tabs with title and URL | |
Supported input: json or jsonlz4 recovery files | |
Default output: title (URL) | |
Output format can be specified as argument | |
""" |