GithubHelp home page GithubHelp logo

n0x-l / daily_cyber_news_feed Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 9 KB

Created using a forked repository (pygooglenews) and a basic Gmail SMTP setup, this script will query and format an email message containing a simple text based message describing the most recent cyber security news and trends. A crontab job can be setup so that this runs every day.

Python 100.00%
cybersecurity automation newsfeed

daily_cyber_news_feed's Introduction

Daily_Cyber_News_Feed

This simple Python script is set up with custom search queries to grab data on recent cyber-related events and attacks. It uses the kotartemiy/pygooglenews repository and a simple Gmail SMTP function to query the data and to send an email after the data has been parsed and formatted.

Instructions

  1. Clone https://github.com/kotartemiy/pygooglenews
  2. Install the pytz python library for doing timezone conversions:
    • via terminal: $ pip install pytz
  3. Enter your username and password for your FROM email, then also enter your TO email and FROM email addresses in the send_email(email_message) function
  4. Either run it $ python3 customCyberFeed.py or set up a crontab job like I did so that it runs every day: https://www.jcchouinard.com/python-automation-with-cron-on-mac/

For the data formatting I created functionality to convert the GMT time to Mountain time, feel free to change this timezone variable at the top of the script to match your own. Might add command-line arguments to set this (or choose not to set it at all in case you want GMT time) in the future.

I've also formatted the data to show the most recent updates at the bottom of the list so that the updates read in ascending order of time published, and to include the related link in case you want to explore an article further.

In the future I'd like to implement a more secure way of setting up the email function and for storing credentials. For now you'll likely have to turn off the setting for blocking insecure apps in your Gmail app so that you can send an email from your script (even though its using SSL). To mitigate the risk I created a Gmail account for this specific purpose so as not to open a primary email account to the risk.

I plan on updating the search queries as I find more relevant or interesting content to be notified on!

It also includes a "breaking news" section at the very end that you can get rid of if you're only looking for cyber content.

Cheers-

daily_cyber_news_feed's People

Contributors

n0x-l avatar lees0n avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.