Skip to content

Instantly share code, notes, and snippets.

View rfjakob's full-sized avatar

rfjakob

  • Vienna, Austria
View GitHub Profile
Process: PSequel [1575]
Path: /Users/USER/Downloads/PSequel.app/Contents/MacOS/PSequel
Identifier: com.psequel.PSequel
Version: 1 (1.2.7)
Code Type: X86-64 (Native)
Parent Process: ??? [1]
Responsible: PSequel [1575]
User ID: 1037
Date/Time: 2015-10-19 16:09:39.961 +0200
@rfjakob
rfjakob / test.log
Created October 19, 2015 21:08
go test ./...
~/src/github.com/hanwen/go-fuse$ go test ./...
ok github.com/hanwen/go-fuse/benchmark 0.025s
? github.com/hanwen/go-fuse/example/autounionfs [no test files]
? github.com/hanwen/go-fuse/example/hello [no test files]
? github.com/hanwen/go-fuse/example/loopback [no test files]
? github.com/hanwen/go-fuse/example/memfs [no test files]
? github.com/hanwen/go-fuse/example/multizip [no test files]
? github.com/hanwen/go-fuse/example/statfs [no test files]
? github.com/hanwen/go-fuse/example/unionfs [no test files]
? github.com/hanwen/go-fuse/example/zipfs [no test files]
@rfjakob
rfjakob / gist:07cba2554984fae9e5ed
Created November 3, 2015 22:15
encfs backtrace
(gdb) thread apply all backtrace
Thread 11 (Thread 0x7f625e7fc700 (LWP 32090)):
#0 0x00007f628177b434 in __memcpy_sse2_unaligned () from /lib64/libc.so.6
#1 0x00007f628330663e in BlockFileIO::cacheReadOneBlock(IORequest const&) const () from /home/jakob/code/encfs/build/libencfs.so.1.9
#2 0x00007f628330719b in BlockFileIO::padFile(long, long, bool) () from /home/jakob/code/encfs/build/libencfs.so.1.9
#3 0x00007f6283306c2b in BlockFileIO::write(IORequest const&) () from /home/jakob/code/encfs/build/libencfs.so.1.9
#4 0x00007f628332bd83 in FileNode::write(long, unsigned char*, long) () from /home/jakob/code/encfs/build/libencfs.so.1.9
#5 0x00007f6283320385 in _do_write(FileNode*, unsigned char*, unsigned long, long) () from /home/jakob/code/encfs/build/libencfs.so.1.9
#6 0x00007f628332a1ae in int std::_Bind<int (*(std::_Placeholder<1>, unsigned char*, unsigned long, long))(FileNode*, unsigned char*, unsigned long, long)>::__call<int, FileNode*&&, 0ul, 1ul, 2ul, 3ul>(std::tuple<FileNode*&&>&&, std::_Ind
@rfjakob
rfjakob / gist:4bea2186b101cd15443a
Created November 3, 2015 23:13
better encfs backtrace
(gdb) bt full
#0 0x00007ff1dcd68430 in __memcpy_sse2_unaligned () from /lib64/libc.so.6
No symbol table info available.
#1 0x00007ff1de8f363e in BlockFileIO::cacheReadOneBlock (this=0x6c6060, req=...) at /home/jakob/code/encfs/encfs/BlockFileIO.cpp:93
tmp = {offset = 0, dataLen = 1024, data = 0x6c60f0 ""}
result = -1
__FUNCTION__ = "cacheReadOneBlock"
#2 0x00007ff1de8f419b in BlockFileIO::padFile (this=0x6c6060, oldSize=-1, newSize=1979297792, forceWrite=false) at /home/jakob/code/encfs/encfs/BlockFileIO.cpp:318
oldLastBlock = 0
newLastBlock = 1932908
@rfjakob
rfjakob / zeroify.sh
Created November 12, 2015 18:53
zeroify.sh - Replace file contents in all files with zeros
#!/bin/bash
set -eu
for FILE in $(find $1 -type f)
do
SIZE=$(stat -c %s $FILE)
truncate -s 0 $FILE
truncate -s $SIZE $FILE
done
@rfjakob
rfjakob / tree.txt
Last active January 4, 2016 00:28
ecryptfs identical names leak
~$ tree Private .Private/
Private
├── 1
│   └── foo
└── 2
└── foo
.Private/
├── ECRYPTFS_FNEK_ENCRYPTED.FWZq4GtMzPp81-Qjpyp9TymLdIIcJGDzYP-wLqPkAInrry-Sfaz86uagCk--
│   └── ECRYPTFS_FNEK_ENCRYPTED.FWZq4GtMzPp81-Qjpyp9TymLdIIcJGDzYP-wGvS4JAGULZNPA.OuWBP6q---
└── ECRYPTFS_FNEK_ENCRYPTED.FWZq4GtMzPp81-Qjpyp9TymLdIIcJGDzYP-wuqV7HssZ9bm4oLb5jqcTeU--
@rfjakob
rfjakob / tree.txt
Created January 4, 2016 00:29
ecryptfs prefix leak
~$ tree Private .Private
Private
├── 1234567890abcdef_x
└── 1234567890abcdef_y
.Private
├── ECRYPTFS_FNEK_ENCRYPTED.FXZq4GtMzPp81-Qjpyp9TymLdIIcJGDzYP-wOBXbOqzuQ44rdGVv7xWcENv5ufXHJ8C2otaetvM0j3U-
└── ECRYPTFS_FNEK_ENCRYPTED.FXZq4GtMzPp81-Qjpyp9TymLdIIcJGDzYP-wOBXbOqzuQ44rdGVv7xWcEOhxx2ZhSt7ar8H.w3nVpnw-
for i in `seq 100 255`; do n=$(perl -E "say \"x\" x $i"); touch $n; done
$ git clean -dxf
$ make &> build.log
make -C cryptopp static
make[1]: Entering directory '/home/jakob.donotbackup/securefs/cryptopp-5.6.2'
g++ -g -march=native -mtune=native -std=c++11 -pipe -Wall -Wextra -pedantic -pthread -O3 -DNDEBUG -ffunction-sections -fdata-sections -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -march=native -pipe -c skipjack.cpp
g++ -g -march=native -mtune=native -std=c++11 -pipe -Wall -Wextra -pedantic -pthread -O3 -DNDEBUG -ffunction-sections -fdata-sections -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -march=native -pipe -c osrng.cpp
In file included from osrng.h:12:0,
from osrng.cpp:9:
aes.h:9:34: warning: extra ‘;’ [-Wpedantic]
/* Copyright (C) 2008-2015 Free Software Foundation, Inc.
This file is part of GCC.
GCC is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3, or (at your option)
any later version.
GCC is distributed in the hope that it will be useful,