Skip to content

Instantly share code, notes, and snippets.

%%%============================================================================
-spec bin_to_hexdigest(binary()) -> binary().
bin_to_hexdigest(Bin) when is_binary(Bin) ->
<<<<(binary:list_to_bin(
case length(S = integer_to_list(I, 16)) of 1 -> [48|S]; 2 -> S end
))/bytes>> || <<I>> <= Bin>>.
-spec hexdigest_to_bin(binary()) -> binary().
hexdigest_to_bin(BinHex) when is_binary(BinHex) ->
decode(Segment) ->
case Segment of
<< SourcePort:16, DestinationPort:16,
SequenceNumber:32,
AckNumber:32,
DataOffset:4, _Reserved:4, Flags:8, WindowSize:16,
Checksum:16, UrgentPointer:16,
Payload/binary>> when DataOffset>4
->
OptSize = (DataOffset - 5)*32,
--
-- xmonad example config file.
--
-- A template showing all available configuration hooks,
-- and how to override the defaults in your own xmonad.hs conf file.
--
-- Normally, you'd only override those defaults you care about.
--
import XMonad
-module(stacktrace_filter).
-compile(export_all).
t() ->
try
sensitive_data_function()
catch
Error:Reason ->
{Error, Reason, erlang:get_stacktrace()}
end.
-define(info, lager:info).
-define(debug, lager:debug).
-define(warning, lager:warning).
-define(error, lager:error).
-define(alert, lager:alert).
-define(mute_level(LogLevel),
begin
error_logger:tty(false),
import com.google.bitcoin.uri.BitcoinURI;
String uri = BitcoinURI.convertToBitcoinURI(address,
output.getValue(),
"very currency",
"such profit");
package main
import (
"fmt"
"time"
"math"
"code.google.com/p/go.crypto/scrypt"
)
func main() {
package secp256k1
/*
#include "./secp256k1/include/secp256k1.h"
*/
import "C"
import ()
{
"Crypto": {
"cipher": "aes-128-cbc",
"cipherparams": {
"iv": "6e38e8499d80916a6767a0c1c70a8cc8"
},
"ciphertext": "6984bc36d8e3e1d9048ee2f2a05be092ca690de8b487fcb0f3b166900b3d960a71cd752f39af26c6cb5db8ca06a524a3",
"kdf": "scrypt",
"kdfparams": {
"dklen": 32,
18:14:50 (master) ~/go/src/github.com/Gustav-Simonsson/go-opencl/cl
> go build -v -x
WORK=/tmp/go-build843416135
github.com/Gustav-Simonsson/go-opencl/cl
mkdir -p $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/
mkdir -p $WORK/github.com/Gustav-Simonsson/go-opencl/
cd /home/gs/go/src/github.com/Gustav-Simonsson/go-opencl/cl
CGO_LDFLAGS="-g" "-O2" /home/gs/golang/pkg/tool/linux_amd64/cgo -objdir $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/ -- -I $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/ -I/opt/opencl-headers/include cl.go context.go device.go kernel.go platform.go program.go queue.go types.go
/home/gs/golang/pkg/tool/linux_amd64/6c -F -V -w -trimpath $WORK -I $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/ -I /home/gs/golang/pkg/linux_amd64 -o $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/_cgo_defun.6 -D GOOS_linux -D GOARCH_amd64 $WORK/github.com/Gustav-Simonsson/go-opencl/cl/_obj/_cgo_defun.c
gcc -I . -fPIC -m64 -pthread -fmessage-length=0 -print-libgcc-file-name