Skip to content

Instantly share code, notes, and snippets.

View Craftplacer's full-sized avatar

Crafti Craftplacer

View GitHub Profile
@define-private-public
define-private-public / HttpServer.cs
Last active May 9, 2024 15:06
A Simple HTTP server in C#
// Filename: HttpServer.cs
// Author: Benjamin N. Summerton <define-private-public>
// License: Unlicense (http://unlicense.org/)
using System;
using System.IO;
using System.Text;
using System.Net;
using System.Threading.Tasks;
@iron9light
iron9light / encoder.js
Created September 3, 2011 16:07
Windows jscript base64 encoder. Drag and drop files you wanna encode to this .js file.
var fsDoOverwrite = true // Overwrite file with base64 code
var fsAsASCII = false // Create base64 code file as ASCII file
var adTypeBinary = 1 // Binary file is encoded
function encode(from, to) {
var inputStream = WScript.CreateObject("ADODB.Stream");
inputStream.Type = adTypeBinary
inputStream.Open();
inputStream.LoadFromFile(from);