This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pwn import * | |
CODE_SIZE = 0x4000 | |
OP_NOP = 0x00 | |
OP_PUSH = 0x01 | |
OP_POP = 0x02 | |
OP_DUP = 0x03 | |
OP_SWAP = 0x04 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <linux/init.h> | |
#include <linux/module.h> | |
#include <linux/kernel.h> | |
#include <linux/in.h> | |
#include <linux/slab.h> | |
#include <linux/delay.h> | |
#include <linux/string.h> | |
MODULE_LICENSE("GPL"); | |
MODULE_AUTHOR("sampriti"); | |
MODULE_DESCRIPTION("qemu cve"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <fcntl.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
#define CMD_ADD 32 | |
#define CMD_FREE 64 | |
#define CMD_READ 16 | |
typedef struct { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdlib.h> | |
#include <stdint.h> | |
#include <string.h> | |
#include <assert.h> | |
#include <fcntl.h> | |
#include <stdio.h> | |
#include <sys/ioctl.h> | |
#include <sys/mman.h> | |
#include <pthread.h> | |
#include <errno.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
M = 136798100663240822199584482903026244896116416344106704058806838213895795474149605111042853590 | |
primes = [2] | |
for x in range(1201): | |
primes.append(next_prime(primes[-1])) | |
sice = [] | |
for x in primes: | |
if M % x == 0: | |
sice.append(x) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Jiahui Chen et al. cryptosystem, 80-bit security | |
# WARNING: very slow implementation. | |
import sys | |
q,n,a,s = (3,59,10,25) | |
m = n+1-a+s | |
FF = GF(q) | |
R = PolynomialRing(FF, ["x{}".format(i) for i in range(n)]) | |
xs = R.gens() | |
def keygen(): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <algorithm> | |
#include <vector> | |
#include <stdint.h> | |
using namespace std; | |
int tbl1[16] = {9, 240, 193, 169, 186, 195, 141, 128, 161, 69, 210, 242, 3, 200, 152, 183}; | |
int tbl2[16] = {218, 218, 238, 202, 208, 137, 128, 90, 199, 249, 162, 67, 79, 90, 82, 253}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from Crypto.Util.number import * | |
n = 118173998641659433141031218423093267548048945830460552160732748274571974743297930821423113390029083098858035838064885829588967199550126084897009304331836294104589302387252278933370240317467378376797843379485665856003112996215247651060003047081838833325054418881162956647931078011461049685774070539302432802113792476309961767049580409488915273417272971605423056480946448420246170538977427027687185230659802277819960185028241326766028592105200802992171 | |
a = 47702774091583083413514954181005338733744246354146014100833529117112767 | |
c = 12568593503732225284833930665556838287412199439692821417647372971869231723559992154443706678410038339647264823124946805716114186285024175170040286493705539280834058460961400557745983656762142889655126327977159776509025806614615683229732063597008220981903454189924787333897642661119487550976064177525965960903757425676552365701751129959682193371999227133565308776511273796468549993234547730548169945552741777405821627017605337784463424463117997971328 | |
e = 6 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ansible.cfg | |
[defaults] | |
host_key_checking = False | |
# hosts | |
all: | |
hosts: | |
192.168.3.12: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
from keras.applications.mobilenet import preprocess_input | |
from keras.models import load_model | |
from keras.preprocessing.image import img_to_array, array_to_img | |
from PIL import Image | |
from imagehash import phash | |
import foolbox | |
import keras | |
NewerOlder