Skip to content

Instantly share code, notes, and snippets.

View DoMINAToR98's full-sized avatar
🎯
Focusing

Kartik Sharma DoMINAToR98

🎯
Focusing
View GitHub Profile
@DoMINAToR98
DoMINAToR98 / slack.py
Created November 13, 2021 23:06
Slack Automation
#!/usr/bin/env python3
import requests
import json
import argparse
import sys
conversationList = "https://slack.com/api/conversations.list"
postMessage = "https://slack.com/api/chat.postMessage"
fileUpload = "https://slack.com/api/files.upload"
apiKey = "key"
channelIDs = {"channel_name": "channel_id"}
from PIL import Image
import binascii
import string
def rgb2hex(r,g,b):
hex = "#{:02x}{:02x}{:02x}".format(r,g,b)
return str(hex)
im = Image.open('bojack.png')
print im
arr=''
pix_val = list(im.getdata())
@DoMINAToR98
DoMINAToR98 / vuln_service_checker.py
Created July 2, 2019 11:19
This simple script finds all the pre existing vulnerabilities present in different softwares installed in your windows machine.
import requests,urllib2,re #for python3 replace urllib2 with urllib.request
from bs4 import BeautifulSoup
from subprocess import Popen,PIPE
URL="https://cve.mitre.org/cgi-bin/cvekey.cgi?keyword="
cmd="wmic product get name,version"
subprocess.call(cmd.split(),shell=True)
p = Popen(cmd, stdin=PIPE, stdout=PIPE, stderr=PIPE)
output, err = p.communicate(b"input data that is passed to subprocess' stdin")
rc = p.returncode
st=output.decode()
import hashlib
import time
import sys
import requests
print 'Helpdeskz v1.0.2 - Unauthenticated shell upload exploit'
if len(sys.argv) < 4:
print "Usage: {} [baseUrl] [nameOfUploadedFile]".format(sys.argv[0])
sys.exit(1)
from pwn import * #Using pwntools for connecting
import re
import textwrap
conn = remote('crypto.hsctf.com',8111)
conn.recvline()
conn.recvline()
conn.recvline()
s=conn.recvline()
print s
t="abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ!?_" #list of characters for bruteforcing
#!/bin/bash
export DEBIAN_FRONTEND=noninteractive;
echo "[*] Starting Install... [*]"
echo "[*] Upgrade installed packages to latest [*]"
echo -e "\nRunning a package upgrade...\n"
apt-get -qq update && apt-get -qq dist-upgrade -y
apt full-upgrade -y
apt-get autoclean
echo "[*] Install stuff I use all the time [*]"
#!/usr/bin/env python
from pyzabbix import ZabbixAPI
import sys
import logging
stream = logging.StreamHandler(sys.stdout)
stream.setLevel(logging.DEBUG)
log = logging.getLogger('pyzabbix')
log.addHandler(stream)
log.setLevel(logging.DEBUG)
#include <stdio.h>
#include <string.h>
unsigned long hashcode = 0x21DD09EC;
unsigned long check_password(const char* p){
int* ip = (int*)p;
int i;
int res=0;
for(i=0; i<5; i++){
res += ip[i];
}
import requests
print """
CVE-2015-6668
Title: CV filename disclosure on Job-Manager WP Plugin
Author: Evangelos Mourikis
Blog: https://vagmour.eu
Plugin URL: http://www.wp-jobmanager.com
Versions: <=0.7.25
"""
@DoMINAToR98
DoMINAToR98 / ez.py
Created March 24, 2019 19:28
Code for LSB-Steganography
from PIL import Image
import binascii
im = Image.open('pic.png')
pix_val = list(im.getdata())
# print pix_val
lsbs=""
for idx,val in enumerate(pix_val):
# Converting each rgb values into binary and keeping only the Least Significant Bit
lsbs=lsbs+'{0:08b}'.format(val[0])[-1]
lsbs=lsbs+'{0:08b}'.format(val[1])[-1]