Skip to content

Instantly share code, notes, and snippets.

View LensHunnel's full-sized avatar

Lens Hunnel LensHunnel

View GitHub Profile
#!/usr/bin/python3
from scapy.utils import rdpcap
from scapy.packet import Packet, bind_layers
from scapy import fields
from scapy.layers.inet import IP
from scapy.all import *
import pcap
class PfSyncHeader(Packet):
name = 'PFSyncHeaderPacket'
@LensHunnel
LensHunnel / DjangoWebpackVuejs.md
Last active May 18, 2020 12:18
Step to use webpack, django and vue js

Steps to use Django with webpack and Vuejs

Requirements

  • python-vuejs:
 pip install python-vuejs
  • webpack-bundle-tracker
@LensHunnel
LensHunnel / plugins_sublime3.md
Last active September 20, 2017 14:53
My essential plugins for Sublime 3
@LensHunnel
LensHunnel / moment.workdays.js
Created April 26, 2017 07:56 — forked from ioleo/moment.workdays.js
introduce 'workdays' mode to moment.js add/subtract methods (PL national holidays)
(function (undefined) {
/**
* moment.easter
* Source: https://github.com/zaygraveyard/moment-easter
* License: MIT
*/
moment.easter = function Easter20ops(year) {
var a = (year / 100 | 0) * 1483 - (year / 400 | 0) * 2225 + 2613;
var b = ((year % 19 * 3510 + (a / 25 | 0) * 319) / 330 | 0) % 29;
var c = 148 - b - ((year * 5 / 4 | 0) + a - b) % 7;
@LensHunnel
LensHunnel / test.py
Created February 20, 2017 11:01
The sample of code I'm using for a project
from lxml import etree
from zeep import Plugin
class MyLoggingPlugin(Plugin):
def ingress(self, envelope, http_headers, operation):
print(etree.tostring(envelope, pretty_print=True))
return envelope, http_headers
def egress(self, envelope, http_headers, operation, binding_options):