This is a quick guide to mounting a qcow2 disk images on your host server. This is useful to reset passwords, edit files, or recover something without the virtual machine running.
Step 1 - Enable NBD on the Host
modprobe nbd max_part=8
package main | |
import ( | |
"fmt" | |
"bytes" | |
"os" | |
"log" | |
"time" | |
"io" | |
"http" |
# | |
# ASPack 2.29 unpacker via. Dynamic Analysis | |
# | |
$:.unshift("C:\\Lib\\metasm") | |
require 'metasm' | |
AS229_OEP_PUSH_OFFSET = 0x420 | |
def _msg(m, error = false) |
type T struct { | |
A int | |
B string | |
} | |
t := T{23, "skidoo"} | |
s := reflect.ValueOf(&t).Elem() | |
typeOfT := s.Type() | |
for i := 0; i < s.NumField(); i++ { |
// You can edit this code! | |
// Click here and start typing. | |
package main | |
import "fmt" | |
import "runtime" | |
import "strings" | |
func identifyPanic() string { | |
var name, file string |
if _, err := os.Stat("/path/to/whatever"); os.IsNotExist(err) { | |
// path/to/whatever does not exist | |
} | |
if _, err := os.Stat("/path/to/whatever"); !os.IsNotExist(err) { | |
// path/to/whatever exists | |
} |
package join | |
import ( | |
"fmt" | |
"strings" | |
"testing" | |
) | |
var ( | |
testData = []string{"a", "b", "c", "d", "e"} |
See also, http://libraryofalexandria.io/cgo/
cgo
has a lot of trap.
but Not "C" pkg also directory in $GOROOT/src
. IDE's(vim) Goto command not works.
So, Here collect materials.
# wrok like: | |
# | |
# raw tcp(9999) tls(127.0.0.1:25500) raw tcp(25501) | |
# client =============> tcp2tls_client.go =====================> tls2tcp_server.go ==============> real server | |
#Generated private key | |
openssl genrsa -out server.key 2048 | |
#To generate a certificate |