Skip to content

Instantly share code, notes, and snippets.

@ochoto
ochoto / oracle_charset_test.sql
Created May 22, 2013 21:17
oracle charset test
NCHR(8364)
@ochoto
ochoto / cursopowershell1.ps1
Created June 19, 2014 12:09
Trabajo con log de eventos y sesiones remotas
$maquinas = (1..10).ForEach{ "CURSOPS" + "{0:D2}" -f $_ }
$hace24h = (get-date).AddHours(-24)
Get-EventLog -LogName System -After $hace24h -EntryType Error,Warning -ComputerName $maquinas|select *|Out-GridView
$mexc = "CURSOPS02","CURSOPS03"
$sess = New-PSSession -ComputerName ($maquinas.Where{$mexc -notcontains $_})
$sess.ForEach{ Invoke-Command -Session $_ -ScriptBlock { dir c:\ } } |sort PSComputerName
@ochoto
ochoto / h2-chromium.js
Created July 26, 2014 10:08
EE22 - Hackit 2 - Chromium
var datos = "click;val;#password;https://hackit.ekparty.org/crx;get;text;show;#mal;#bien;NETWORK ERROR!;ajax;bind;#sendButton;ready".split(";");
function enviar(pass) {
resultado = "kk"
$[datos[10]]({
url: datos[3],
type: datos[4],
async: !1,
data: {password: pass},
dataType: datos[5],
@ochoto
ochoto / sca.py
Created July 26, 2014 19:23
raspberry
i=IP(src="10.0.2.15",dst="192.168.42.1")
r=ICMPv6EchoReply(id=0x0007,seq=300)
send(i/r)
package whoop.whoop
import java.util.concurrent.TimeUnit
import org.openjdk.jmh.annotations._
import scala.util.control.NoStackTrace
@State(Scope.Benchmark)
@BenchmarkMode(Array(Mode.AverageTime))
@ochoto
ochoto / angr.py
Created April 2, 2019 12:23
Crackme solve for GE13 H5 with angr explorer with FIND and AVOID addresses
#!/usr/bin/env python2
"""
In this challenge we are given a binary that checks an input given from stdin.
If it is correct, it will call get_flag in a separate library and print(it.)
However, we don't have the library so need to find the correct input and input
it over netcat. If it is incorrect, only 'Goodbye' is printed.
Reversing shows that the program verifies the input character by character.]
Because of the program's linear nature and reliance on verbose constraints,
angr is perfect for solving this challenge quickly. On a virtual machine
@ochoto
ochoto / r-to-python-data-wrangling-basics.md
Created June 4, 2020 16:24 — forked from conormm/r-to-python-data-wrangling-basics.md
R to Python: Data wrangling with dplyr and pandas

R to python data wrangling snippets

The dplyr package in R makes data wrangling significantly easier. The beauty of dplyr is that, by design, the options available are limited. Specifically, a set of key verbs form the core of the package. Using these verbs you can solve a wide range of data problems effectively in a shorter timeframe. Whilse transitioning to Python I have greatly missed the ease with which I can think through and solve problems using dplyr in R. The purpose of this document is to demonstrate how to execute the key dplyr verbs when manipulating data using Python (with the pandas package).

dplyr is organised around six key verbs: