Skip to content

Instantly share code, notes, and snippets.

View adi928's full-sized avatar

Aditya Nath adi928

View GitHub Profile
@adi928
adi928 / nmapBaseline.py
Last active December 3, 2019 21:07
Includes a function for scanning the network and running comparison on Nmap XML outputs. Needs Sanitizing
import nmap
from datetime import datetime
import difflib
from pathlib import Path
## Run nmap
def runNmap():
scanFileName = 'scan-' + str(datetime.now())
argStr = '-sC -sV'
nmapCmd = nmap.PortScanner()
@adi928
adi928 / pattern.py
Last active January 19, 2020 21:05
#! /usr/local/bin/python
import sys
import string
import re
import argparse
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@adi928
adi928 / crawler
Created September 28, 2019 16:01
from http_crawler import crawl
if __name__ == '__main__':
for rsp in crawl('https://admissions.iusb.edu/', exceptions='https://students.iusb.edu/about/big-list.html'):
if rsp.status_code == 200:
print('Got {}'.format(rsp.url))
#include <stdio.h> // Used for printf() statements
#include <wiringPi.h> // Include WiringPi library!
// Pin number declarations. We're using the Broadcom chip pin numbers.
const int ledPin1 = 18; // PWM LED - Broadcom pin 18, P1 pin 12
const int ledPin2 = 23; // Regular LED - Broadcom pin 23, P1 pin 16
const int ledPin3 = 24;
const int ledPin4 = 25;
const int pwmValue = 1024; // Use this to set an LED brightness
@adi928
adi928 / aesEncrypt.cpp
Created September 20, 2018 14:42
Key Expansion included AES encrypt
#include <iostream>
#include "AESConstants.h"
#include <fstream>
#include <string>
using namespace std;
// Input the plaintext and the key
void inputData(char* plainText, char* key)
{
// Variable to contain user's file name
@adi928
adi928 / gist:843bc400e7b6d782fa24b95812d415c2
Created December 12, 2017 11:15
Error for Begin conversation in Postman - Guice error -Need rebase
{
"errors": [
{
"reason": "UNKNOWN",
"message": "An unexpected error occurred: Unable to provision, see the following errors:\r\n\r\n1) null returned by binding at com.cerner.cpoe.conversation.rest.common.guice.ConversationRestModule.providesCodeSystem()\r\n but the 3rd parameter of com.cerner.cpoe.availableactions.ml.delegate.RetrieveAvailableActionsForRxDelegate.<init>(RetrieveAvailableActionsForRxDelegate.java:77) is not @Nullable\r\n while locating com.cerner.system.code.CodeSystem\r\n for the 3rd parameter of com.cerner.cpoe.availableactions.ml.delegate.RetrieveAvailableActionsForRxDelegate.<init>(RetrieveAvailableActionsForRxDelegate.java:77)\r\n while locating com.cerner.cpoe.availableactions.ml.delegate.RetrieveAvailableActionsForRxDelegate\r\n for the 2nd parameter of com.cerner.cpoe.availableactions.ml.delegate.RetrieveAvailableActionsDelegate.<init>(RetrieveAvailableActionsDelegate.java:76)\r\n while locating com.cerner.cpoe.availableactions.ml.delegate.