Skip to content

Instantly share code, notes, and snippets.

#include <stdio.h>
#include <unistd.h>
int main(){
setuid(0);
execl("/bin/bash",NULL);
}
/*
* gcc -o g5_hiddev g5_hiddev.c
*
* g5_hiddev - first working hack!
*
* by
* Andreas "gladiac" Schneider <[email protected]>
* Peter "piie" Feuerer <[email protected]>
*
* Additional Info:
@userid
userid / keepalived.conf
Created September 15, 2017 02:52
keepalived简单配置
! Configuration File for keepalived
global_defs {
notification_email {
acassen
}
# 机器标识,通常可设为hostname
router_id ha_host47
vrrp_version 3
CC=clang ./configure \
--prefix=/opt/php7.0.14 \
--with-config-file-path=/opt/php7.0.14/etc \
--with-config-file-scan-dir=/opt/php7.0.14/etc/conf.d \
\
--enable-opcache \
--enable-fpm \
--enable-pdo \
--enable-sockets \
--enable-pcntl \
git clone https://github.com/neovim/neovim
cd neovim
mkdir build && cd build
CC=clang CFLAGS="-O2" cmake .. -DCMAKE_INSTALL_PREFIX=/usr/
CC=clang make -j4 CMAKE_EXTRA_FLAGS=-DCMAKE_INSTALL_PREFIX=/usr CMAKE_BUILD_TYPE=Release
#include <unistd.h>
#include <stdio.h>
#include <stdarg.h>
#include <string.h>
#include <stdlib.h>
# define MAXLINE 2048
#define Linux
# echo "deb http://deb.debian.org/debian/ unstable main" > /etc/apt/sources.list.d/unstable-wireguard.list
# printf 'Package: *\nPin: release a=unstable\nPin-Priority: 200\n' > /etc/apt/preferences.d/limit-unstable
# apt update
@userid
userid / linux burn CD.txt
Created June 5, 2017 10:46
刻录音乐cd
cuebreakpoints -i cue '梁静茹 - 闪亮的星.cue' | shnsplit -n %02d '梁静茹 - 闪亮的星.ape'
cdrecord -v -eject -speed 1 -pad dev=/dev/sr0 -dao -swab *.wav
/*
* Copyright (C) 2012 DataStax Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@userid
userid / get_time_from_UUID1.pl
Last active May 24, 2017 11:15
extract a date from a UUID type1 using Perl?
#!/usr/bin/perl
$uuid= shift || 'ef802820-46b3-11e2-bf3a-47ef6b3e28e2';
$uuid =~ s/-//g;
my $timelow = hex substr( $uuid, 2 * 0, 2 * 4 );
my $timemid = hex substr( $uuid, 2 * 4, 2 * 2 );
my $version = hex substr( $uuid, 2 * 6, 1 );
my $timehi = hex substr( $uuid, 2 * 6 + 1, 2 * 2 - 1 );