Skip to content

Instantly share code, notes, and snippets.

View ansarid's full-sized avatar

Daniyal Ansari ansarid

  • Texas A&M Engineering Experiment Station
  • College Station, Texas
View GitHub Profile

MD5 Collision with CRC32 Preimage

Here's the scenario: We want to craft two different messages with the same MD5 hash, and a specific CRC32 checksum, simultaneously.

In other words, we want an MD5 collision attack and a CRC32 preimage attack.

This might seem like a contrived scenario, but it's exactly the one I faced while producing my PNG hashquine (Yes OK maybe that's also a contrived scenario, cut me some slack).

On its own, a CRC32 preimage attack is trivial. You can craft a 4-byte suffix that gives any message a specific checksum, calculated using a closed-form expression (which I am too lazy to derive, not even with assistance from Z3). It's not an attack per-se, since CRC32 was never meant to be cryptograpically secure in the first place.

@pvandervelde
pvandervelde / move_scuttle.py
Created May 29, 2022 05:29
A simple ROS node to move SCUTTLE to a goal
#!/usr/bin/env python
from math import pow, atan2, sqrt, copysign
import rospy
from geometry_msgs.msg import Twist, Pose, PoseWithCovariance
from nav_msgs.msg import Odometry
from tf.transformations import euler_from_quaternion, quaternion_from_euler
class ScuttleControl:
@pvandervelde
pvandervelde / scuttle-with-ros-in-the-real-world.md
Created May 22, 2022 03:48
Getting started with ROS and SCUTTLE in the real world

Running SCUTTLE with ROS in the real world

In order to run a physical SCUTTLE using ROS you will need to first install all the software on a Raspberry PI. First install the Raspberry PI OS on the SD card. Make sure to configure both SSH and the wifi options so that you can connect to the Raspberry Pi once it starts up. The Raspberry Pi Imager has some advanced options that allow you to set both the SSH credentials and the Wifi options.

Once you have installed the OS image you can plug the SD card into the Raspberry Pi and power it up. When the Pi shows up on the network you can SSH in and install ROS Noetic and all the other libraries you need

@pvandervelde
pvandervelde / scuttle-with-ros-and-gazebo.md
Last active May 21, 2022 09:55
Getting started with ROS and Gazebo for SCUTTLE

Running SCUTTLE in Gazebo

In order to run a virtual SCUTTLE in Gazebo you will first need to install ROS Noetic on Ubuntu 20.04. This can be a physical machine, e.g. a spare laptop or a VM. If you're building a VM you can follow these instructions to get a VM with ROS noetic installed. In all cases you want to make sure you have at least the following ROS packages (and their dependencies) installed.

  • ros-noetic-desktop-full
  • ros-noetic-catkin
  • ros-noetic-navigation
@Lassi-Koykka
Lassi-Koykka / xkcd.zsh
Last active March 24, 2022 14:29
A simple Zsh/Bash function for getting and displaying a random xkcd comic in the Kitty terminal
# XKCD
# Add this to your .bashrc or if you are using oh-my-zsh add a functions.zsh file under your oh-my-zsh/custom folder.
# Requirements:
# - Kitty terminal
# - jq
# - ImageMagick
function xkcd () {
comicNum=$1
@pvandervelde
pvandervelde / create-rpi4-with-ros-noetic-and-opencv.md
Last active May 21, 2022 04:49
Steps to create a Raspberry Pi 4 image with ROS noetic and OpenCV

Ros on Raspberry Pi 4 - OS

Install git

sudo apt-get install git

Install zsh

NOTE: Picked zsh because it has better highlighting and completion, but also catkin generates zsh scripts.

@Pyrestone
Pyrestone / setup_noetic.md
Created December 23, 2021 11:16
ROS Noetic Install on NVIDIA Jetson Nano (Ubuntu 18.04)

ROS Noetic Install on jetson nano (Ubuntu 18.04)

This guide is derived from the official Noetic setup page, which can be found here: http://wiki.ros.org/noetic/Installation/Source

This version includes some customizations for missing packages on Ubuntu 18.04 which the jetson nano OS uses. I think this installation should work on most ubuntu 18.04 installations, but I can give no guarantees.

System and python dependencies

@dmalawey
dmalawey / SCTL_Feedback.md
Last active October 26, 2022 17:14
SCUTTLE Kits - Feedback from Early Adopters and Insightful Persons

A message to all:

Please leave your feedback as a comment below, and if your feedback has many points, kindly number them and it will help us organize.

If you love formatting: See Markdown Guide Cheat Sheet

PART_0 Query Topics 10.20

  1. Platform for payload
    • Is there a kind of Payload rack design in place?
  2. Buying Extra Hardware
@azidanit
azidanit / tutorial_python3_melodic.md
Created July 21, 2021 04:14
How To Python 3 On ROS MELODIC

The Insane Techie

Working With Python 3 In ROS Kinetic Or Melodic

May 7, 2020 ROS • python kinetic • melodic • robotics • python • ROS • python

ROS (Robot Operating System) - Documentation - http://wiki.ros.org/

@rafaelpadovezi
rafaelpadovezi / git-bash-fish.md
Last active May 20, 2024 04:31
Using fish shell with git bash on windows

Using fish shell with git bash on windows

To install fish shell on windows the options are:

  • Cygwin
  • WSL
  • MSYS2

Since git bash is based on MSYS2 it seems a good fit to install fish. The problem is that git bash is a lightweight version of MSYS2 which does not include pacman as a package management, used to install fish.

This OS thread has great suggestions on how to solve this problem including using the full MSYS2. But the best solution for me was this answer by Michael Chen which installs pacman on git bash.