Skip to content

Instantly share code, notes, and snippets.

View vppillai's full-sized avatar
😃

Vysakh P Pillai vppillai

😃
View GitHub Profile
#include <linux/module.h>
MODULE_LICENSE("Dual BSD/GPL");
#include<linux/module.h>
#include<linux/init.h>
#include<linux/kernel.h>
MODULE_LICENSE("GPL"); /*else kernel complaints about kernel taint*/
int simple_init(void)
{
printk(KERN_ALERT"Hello kernel space world\n"); /*Kernel mode printf - messages appear in /var/log/messages . or use command dmesg | tail*/
return 0;
}
int simple_exit(void)
<!DOCTYPE HTML>
<html>
<head>
<style>
body {
margin: 0px;
padding: 0px;
}
</style>
</head>
#!/bin/bash
stty -F /dev/ttyUSB0 speed 115200 cs8 -cstopb -parenb
coproc d { nc -l -p 81 -q 0; }
nc -l -p 80 -q 1 > /dev/null <<-ENDOFPAGE
<html>
<body>
<script type="text/javascript">
var exampleSocket=0;
exampleSocket = new WebSocket("ws://localhost:81", "protocolOne");
@vppillai
vppillai / websocketFinal.sh
Created October 24, 2014 04:19
websocketFinal.sh
#!/bin/bash
stty -F /dev/ttyUSB0 speed 115200 cs8 -cstopb -parenb
coproc d { nc -l -p 81 -q 0; }
echo $$
until read line; line=`tr -d '\r\n'<<<$line`; test -z "$line"; do
test "${line:0:18}" = "Sec-WebSocket-Key:" && key=${line:19}
test "${line:0:22}" = "Sec-WebSocket-Version:" && ver=$line
done <&${d[0]}
rkey=`echo -n ${key}258EAFA5-E914-47DA-95CA-C5AB0DC85B11|openssl dgst -sha1 -binary|base64`
echo -ne "HTTP/1.1 101 Switching Protocols\r\n" >&${d[1]}
<!DOCTYPE HTML>
<html> <head>
<style>
body {
margin: 0px;
padding: 0px;
}
</style> </head>
<body>
<div id="container"></div>
#!/bin/sh
#
# $Id: dhcp3-server.init.d,v 1.4 2003/07/13 19:12:41 mdz Exp $
#
# On what interfaces should the DHCP server (dhcpd) serve DHCP requests?
# Separate multiple interfaces with spaces, e.g. "eth0 eth1".
INTERFACES=""
# Sanity checks
movlw 0xf0 ; moving value 0xf0 to location 0x22 through w register
movwf 0x22
call rtn1 ; a jump instruction to label rtn1, pushes 03 (next PC)
; to stack and loads 05 (rtn1) to PC
movfw 0x24 ;moving value in location 0x24 to location 0x23 through
;w register
movwf 0x23
rtn1: movlw 0x8f ;moving value 0x8f to location 0x24 in data
movwf 0x24 ; memory
call rtn2 ;pushes 08 to stack and loads 11 to PC.
No data is intentionally collected and stored by this app. Some data might end up in logs and might end up getting transfered . Please use this only at your own risk and if you agree not to hold anyone liable for anything related to this app.
@vppillai
vppillai / Config.in
Last active February 4, 2019 13:47 — forked from clemtibs/Config.in
cURL package information for addition in buildroot. Copy both files to /package/curl and don't forget to add 'source "package/curl/Config.in"' to your top level Config.in
config BR2_PACKAGE_LIBCURL
bool "libcurl"
help
cURL is a tool for getting files from FTP, HTTP, Gopher, Telnet,
and Dict servers, using any of the supported protocols.
http://curl.haxx.nu/
config BR2_PACKAGE_CURL
bool "curl binary"