Photo by Ibrahim Rifath on Unsplash

The 50/30/20 rule was popularized by Senator Elizabeth Warren’s book All Your Worth: The Ultimate Lifetime Money Plan. The basic methodology of the rule is you allocate a percentage of your after-tax income into 3 categories: 50% on your needs, 30% on your wants, and 20% on your savings and paying down debt.

50% Needs

Needs are categorized as things you are obligated to pay to survive. These can include your rent or mortgage payments, utilities, health care, groceries, transportation, childcare, and minimum debt payments. …


Photo by Marius Masalar on Unsplash

Introduction

Python is currently one of the fastest growing and most in demand languages. It’s usefulness has been proven in software engineering and data science. Another useful application of the language is for building cyber security tools. In this article, I would like to share with you some of my favorite libraries for building cyber security tools.

Requests

Requests is one of my most used libraries by far and it is for many others as it is one of the most downloaded Python libraries at 400,000 downloads each day. Requests is used for crafting HTTP requests within your Python scripts. …


Introduction

Today I wanted to show you multiple ways that you are able to have your console output be colored in your Python scripts.

Termcolor

The first module we’ll explore is termcolor. Termcolor allows you to use ANSI color formatting with your console output. To install termcolor you run:

$ pip install termcolor

Once termcolor is installed you can use it to color your output:


Photo by neil godding on Unsplash

I recently read the story “The best podcasts for new coders, and the best tools for listening to them” by Ayo Isaiah and thought it was a great story and was inspired to write my own for cyber security podcasts. Listening to podcasts has been something that I have turned to more and more over music during a commute or while at the gym since for me it is just as enjoyable as music and I get to learn while doing other things.

I think that cyber security podcasts are great to listen to for anyone interested in the field…


Introduction

Another great tool to learn how to make is a port scanner. These tools can be very useful to be able to identify opened ports on your hosts or firewalls that are not meant to be open. Building a port scanner can be very simple but allows for other features to be added. Today we will be building a simple port scanner in 20 lines of code. Lets get started!

Building the Tool

First we will need to import a few standard libraries to help us out

The socket library is a low level networking interface library that allows us to create…


Introduction

Every day we see on the news of a new data breach or a new ransomware attack plaguing our society. With the rapid adoption of technology in all sectors it is becoming increasingly difficult to protect and secure it properly. According to the Ponemon Institute’s 2017 State of Cybersecurity in Small & Medium-Sized Businesses report, the percentage of small businesses that have experienced a cyber attack increased from 55% in 2016 to 61% in 2017 and small businesses that experienced a data breach increased from 50% in 2016 to 54% in 2017. …


Introduction

Today I want to show you how you can turn a python script from this:

$ python3 coolscript.py

To this:

$ coolscript

How It’s Done

How you are able to change a python script into a full fledged CLI command is by leveraging setup.py. I will demonstrate this by creating a program that will perform a caesar cipher on any text you provide it.

Project Structure

First we will need to create our projects directory:

$ mkdir caesar 
$ cd caesar
$ mkdir caesar
$ touch setup.py
$ touch caesar/__init__.py
$ touch caesar/caesar.py

And what we should be left with is a directory structure that…


Introduction

I believe that it is very important to understand not only how to use a tool but also how it works. Today I will be demonstrating how you can create a CLI tool in Python to hash files.

Setup

I am going to use Python3 to build this tool so you will need to make sure you have Python3 installed. You can do this by running:

$ python3 -V
Python 3.6.7

Once we have verified that Python3 is installed we will create a new file called pyhash.py. This will be the file we will write all of our code in.

$…

Chris Doucette

Cybersecurity Analyst and Finance Enthusiast

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store