Skip to content

Instantly share code, notes, and snippets.

View jens1o's full-sized avatar
💻

Jens Hausdorf jens1o

💻
View GitHub Profile
@jens1o
jens1o / my.cnf
Created January 29, 2024 22:10 — forked from fevangelou/my.cnf
Optimized my.cnf configuration for MySQL/MariaDB (on Ubuntu, CentOS, Almalinux etc. servers)
# === Optimized my.cnf configuration for MySQL/MariaDB (on Ubuntu, CentOS, Almalinux etc. servers) ===
#
# by Fotis Evangelou, developer of Engintron (engintron.com)
#
# ~ Updated December 2021 ~
#
#
# The settings provided below are a starting point for a 8-16 GB RAM server with 4-8 CPU cores.
# If you have different resources available you should adjust accordingly to save CPU, RAM & disk I/O usage.
#
@jens1o
jens1o / exploiting-tridactyl.md
Last active April 2, 2021 13:37
Get calc.exe with and by Tridactyl - Vulnerability analysis

Watch a video Get calc.exe with and by Tridactyl

The extension Tridactyl

Tridactyl provides a different kind of way how you can browse the web. It's keyboard-bound and kind of related to vim (you can scroll, go to start/end of the page, zoom, search in page with keyboard shortcuts).

A GIF showing some basic functionality of Tridactyl, browsing with keyboard shortcuts, navigating the web.

(Source: https://github.com/tridactyl/tridactyl/blob/37ad6cf4ccadd111e440fca1cb85ce48e8f90693/doc/AMO_screenshots/trishowcase.gif, licensed under the Apache License, Author: Oliver Blanthorn)

It has a command line interface at the bottom of the webpage (as seen in the GIF). You can try it out yourself here: [https://github.com/tridactyl/tridactyl/#installing](

@jens1o
jens1o / Cargo.toml
Created February 26, 2019 18:45
Project Euler: #196
[package]
name = "problem-one-hundred-and-ninety-six"
version = "0.1.0"
authors = ["Jens Hausdorf <mail@jens-hausdorf.de>"]
edition = "2018"
[dependencies]
yansi = "0.5.0"
<?php
$emptyArray = [];
$numberArray = range(0, 10000);
$charArray = array_merge(range('a', 'z'), range('A', 'Z'));
foreach([$emptyArray, $numberArray, $charArray] as $array) {
$startTime = microtime(true);
for ($i = 0; $i <= 100000; $i++) {
if (in_array('', $array, true)) {
@jens1o
jens1o / settings.json
Created August 2, 2017 19:53
my settings.json
{
"emmet.useNewEmmet": true,
"workbench.colorCustomizations": {
"editorCursor.foreground": "#D19A66",
"activityBarBadge.background": "#0078CD",
"activityBarBadge.foreground": "#ffffff",
"statusBar.foreground": "#cccccc",
"editor.lineHighlightBackground": "#2C313A"
/*,
"kflist.focusBackground": "#0B3952",
<?php
class Example {
public $cool = false;
public function setCoolness() {
$this->cool = true;
return $this;
}