Skip to content

McHughSecurity

  • Home
  • Blog
  • Security Operations
  • DFIR
    • Reverse Engineering
      • Dynamic Analysis
      • Static Analysis
  • Vuln. Mgmt
  • Intelligence
    • Open-Source Intelligence
    • Threat Intelligence
      • AIL Framework
      • MISP – Open Source Threat Intelligence Platform
      • OpenCTI
  • Threat Modelling
    • Attack Libraries
    • Attack Trees
    • Mitigating Techniques
    • SaaS Threat Modelling
    • Threat Models
    • Tools
    • Validating Threat Mitigations
  • Toggle search form
  • TraceLabs Missing Persons 11th of April 2020 Open-Source Intelligence
  • [Part 4] Building a Threat Integration and Testing Lab – MISP Threat Intelligence Sharing Platform Build
  • Exporting Maltego Graphs to MISP Intelligence
  • [Part 3] Building a Threat Integration and Testing Lab – Splunk Enterprise Build
  • Building a parallel-analysis Cuckoo server Digital Forensics & Incident Response
  • Security Orchestration with Shuffle.io Design
  • Hardening TheHive4 and Cortex for public deployment Build
  • Loading Windows Event Logs to Elasticsearch Digital Forensics & Incident Response

Auto-updating Ubuntu 20.04 in less than 2 minutes

Posted on April 26, 2022April 26, 2022 By A.McHugh No Comments on Auto-updating Ubuntu 20.04 in less than 2 minutes

If you are like me and deploy lots of small instances of VMs all over the place for various functions, you will find applying updates to them all consistently and in a responsive manner a logistical issue. Fortunately, there is an auto-update function within Ubuntu which can be configured in a few minutes.

This very quick snippet of code is intended to be your all-in-one script for applying system security updates when they come out, and queue up your system for a reboot when required. A word of warning however – if you have not configured services to start on boot, this may break your capability until you manually intervene.

sudo apt install -y unattended-upgrades update-notifier-common
sudo cp /etc/apt/apt.conf.d/50unattended-upgrades ~/50unattended-upgrades.backup
echo 'Unattended-Upgrade::Automatic-Reboot "true";' >> /etc/apt/apt.conf.d/50unattended-upgrades
echo 'Unattended-Upgrade::Automatic-Reboot-WithUsers "true";' >> /etc/apt/apt.conf.d/50unattended-upgrades
sudo dpkg-reconfigure -plow unattended-upgrades

The default configuration of 50unattended-upgrades should be fit for purpose as it. There are however two lines which need to be added to enable the automatic reboot, and also automatic reboot with users connected (could be optional, it depends on your system use case etc).

Contents of 50unattended-upgrades

When prompted by dpkg-configure, select ‘Yes’ to automatically download and install stable updates.

dpkg-reconfigure -plow unattended-upgrades prompt

Related

Operate

Post navigation

Previous Post: Feeding Analysis Information Leak (AIL) Framework

Related Posts

  • Loading Windows Event Logs to Elasticsearch Digital Forensics & Incident Response
  • Extracting RAM from VirtualBox session Digital Forensics & Incident Response

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

11 − 8 =

Recent Posts

  • Auto-updating Ubuntu 20.04 in less than 2 minutes
  • Feeding Analysis Information Leak (AIL) Framework
  • An Introduction to Threat Intelligence
  • Deploying MISP on DigitalOcean or Vultr Cloud Hosting
  • Building CCCS’ AssemblyLine for Static Analysis

Search

Recent Posts

  • Auto-updating Ubuntu 20.04 in less than 2 minutes
  • Feeding Analysis Information Leak (AIL) Framework
  • An Introduction to Threat Intelligence
  • Deploying MISP on DigitalOcean or Vultr Cloud Hosting
  • Building CCCS’ AssemblyLine for Static Analysis

Archives

  • April 2022
  • July 2021
  • June 2021
  • May 2021
  • April 2021
  • March 2021
  • February 2021
  • January 2021
  • September 2020
  • April 2020
  • March 2020
  • January 2020
  • May 2019
  • Building Structured Threat Intelligence (STIX) from FBI notices MISP - Open Source Threat Intelligence Platform
  • Exporting Maltego Graphs to MISP Intelligence
  • Building TheHive4 (4.0.5) and configuring MISP, Cortex and Webhooks. Digital Forensics & Incident Response
  • Security Orchestration with Shuffle.io Design
  • Using the workflow taxonomy in MISP MISP - Open Source Threat Intelligence Platform
  • Deploying (and using) TheHive4 [Part 1] Build
  • Cuckoo Dynamic Malware Analysis Digital Forensics & Incident Response
  • [Part 2] Building a Threat Integration and Testing Lab – Elastic Cloud Enterprise (On-Premises) Build

Categories

  • AIL Framework
  • Blog
  • Build
  • Design
  • Digital Forensics & Incident Response
  • Frameworks
  • Intelligence
  • MISP – Open Source Threat Intelligence Platform
  • Open-Source Intelligence
  • Operate
  • Security Operations
  • Static Analysis
  • Threat Intelligence

Copyright © 2022 McHughSecurity.

Powered by PressBook News Dark theme