Skip to content

Instantly share code, notes, and snippets.

Per Buer perbu

Block or report user

Report or block perbu

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View trap1.js
This prints out A,B,C,D and E.
What is the order and what is printed after E:
myAdd = (a, b) => {
return new Promise((resolve, reject) => {
resolve(a + b);
perbu / nacl.txt
Created Dec 19, 2017
Example NaCl config for a simple firewall.
View nacl.txt
Iface outside {
index: 0
Iface inside {
View full nat example
Iface eth0 dhcp
eth0.index: 0
Iface k1 {
index: 2,
prerouting: [ fw, mydnat ]
perbu /
Created Sep 24, 2017 — forked from Samuirai/
G-WAN Captcha Decode

G-WAN is a new free web server. They seem to be very proud of it, or at least just want to make a lot of money. Well anyway, in almost every sentence they write, they claim that they are 20% cooler than anything else. It feels a bit arrogant. I have to admit, I don't know a lot about web servers, so I can't speak to how good they are.

However, then I saw their Captcha example. I also don't know much about machine learning algorithms, OCR, and stuff like that, but I do know how to read pixels. I also know how to compare values with python :P


They say the following about their Captcha:

use IO::Socket;
use constant MAXWRITE => 2000; #biggest write we'll attempt
use strict;
use warnings;
$|++; # autoflush stdout
my ($host,$port) = @ARGV;
View gist:4760d16227c495bd1fca343b505c4af1
o oooooo o
oo oooooooooo oo
oo oooooooooCoooooooooo oo
o oooooooooooooooooooooooo o
o oooooooooooooooooooooooCoooooooooo o
o oooooooooooooCoooooooooooooooooooooooooooooooooooooo o
oo oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo oo
o oooooooooooooooooooooooCoooooooooooooooooooooooooooooooooooooooooo o
View gist:ed005753736c2f1f9eb796ceb299ba4e
yyhhyso++++++oos+:. .:+soo++++++osyhddd
yyyyyyhysoos+:`` ``:+sooyhddddddd
yyyyyyyyyNd+:` `-/smddddddddd
yyyyyyyyyNdddho+. .//++/:mddddddddd
View gist:e8650e29a4df6c5dd0185bab95cdbdec
**** PANIC: ****
Stack protector: Canary modified
**** CONTEXT: ****
Connection::on_data: data from (ESTABLISHED)
GET /api/dashboard HTTP/1.1
Connection: keep-alive
Accept: application/json, text/plain, */*
View gist:022c9ffb8ceb82caff88b1ad9697aaf5
[ 25%] Building CXX object CMakeFiles/diskbuilder.dir/main.cpp.o
In file included from /Users/perbu/git/IncludeOS/diskimagebuild/main.cpp:10:
/Users/perbu/git/IncludeOS/diskimagebuild/filetree.hpp:22:15: warning: default template arguments for a function template are a C++11 extension [-Wc++11-extensions]
template <int Mult = SECT_SIZE>
^ ~~~~~~~~~
/Users/perbu/git/IncludeOS/diskimagebuild/filetree.hpp:54:10: error: no member named 'emplace_back' in 'std::__1::vector<Dir, std::__1::allocator<Dir> >'
~~~~ ^
/Users/perbu/git/IncludeOS/diskimagebuild/filetree.hpp:59:11: error: no member named 'emplace_back' in 'std::__1::vector<File, std::__1::allocator<File> >'
View QNAP disk failure log
[874377.384908] ata7.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen
[874377.392102] ata7.00: failed command: FLUSH CACHE EXT
[874377.397198] ata7.00: cmd ea/00:00:00:00:00/00:00:00:00:00/a0 tag 0
[874377.397198] res 40/00:01:00:4f:c2/00:00:00:00:00/00 Emask 0x4 (timeout)
[874377.410958] ata7.00: status: { DRDY }
[874377.414753] ata7: hard resetting link
[874387.767905] ata7: softreset failed (1st FIS failed)
[874387.772922] ata7: hard resetting link
[874398.128877] ata7: softreset failed (1st FIS failed)
[874398.133885] ata7: hard resetting link
You can’t perform that action at this time.