Skip to content

Instantly share code, notes, and snippets.

View Irishsmurf's full-sized avatar
💭
idk is this twitter

David K Irishsmurf

💭
idk is this twitter
View GitHub Profile
@Irishsmurf
Irishsmurf / import.py
Last active December 3, 2022 17:28
Imports Radarr Downloads into a Directory/File symlink structure
#
# Script that iterates over Movie files in a directory, and symlinks into a destination.
#
#
import os
import re
import logging
@Irishsmurf
Irishsmurf / Tokyo to Paris
Last active May 21, 2020 11:28
Tokyo to Paris
dave@tokyo:~$ sudo lft 185.60.112.157
Tracing ....*********
TTL LFT trace to 185.60.112.157:80/tcp
1 216.239.57.137 149.0ms
2 172.253.65.175 219.9ms
3 216.239.58.128 221.4ms
4 108.170.246.177 219.9ms
** [80/tcp no reply from target]
dave@tokyo:~$ sudo traceroute -T 185.60.112.157
+-----+---------------+-------+-------+--------+--------+----------+----------+---------+---------+-----------+--------------+---+
|Row |Netsack |Nine |Ten |Eleven |Twelve |Thirteen |Fourteen |Fifteen |Sixteen |Seventeen |TotalCommits | |
+-----+---------------+-------+-------+--------+--------+----------+----------+---------+---------+-----------+--------------+---+
|1 |google.com |15652 |27959 |49988 |58081 |78770 |131874 |208796 |383820 |19432 |985531 | |
|2 |microsoft.com |473 |7266 |6425 |11655 |21069 |32527 |123876 |162662 |11759 |381380 | |
|3 |apple.com |13216 |8826 |5855 |6129 |10063 |15190 |18272 |16245 |1677 |112075 | |
|4 |amazon.com |0 |34 |164 |377 |2217 |2836 |7409 |7514 |815 |21368 | |
+-----+---------------+-------+-------+--------+--------+----------+----------+---------+---------+--------
+-----+-------------+------+-----+--------+--------+----------+----------+---------+---------+-----------+--------------+
|Row |Netsack |Nine |Ten |Eleven |Twelve |Thirteen |Fourteen |Fifteen |Sixteen |Seventeen |TotalCommits |
+-----+-------------+------+-----+--------+--------+----------+----------+---------+---------+-----------+--------------+
|1 |tcd.ie |0 |0 |19 |274 |446 |1816 |2941 |3305 |160 |8962 |
|2 |mydit.ie |0 |0 |0 |0 |38 |576 |1518 |3368 |59 |5559 |
|3 |ul.ie |0 |0 |67 |443 |426 |1313 |1295 |20 |12 |3576 |
|4 |nuim.ie |2 |2 |282 |142 |761 |352 |221 |354 |143 |2264 |
|5 |mail.dcu.ie |0 |2 |0 |12 |329 |436 |520 |757 |89 |2145 |
+-----+-------------+------+-----+--------+-----
{
"Version": "2012-10-17",
"Id": "Policy",
"Statement": [
{
"Sid": "ListBucket",
"Effect": "Deny",
"Principal": "*",
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<somebucket>",
def decode_ip_packet(s):
d={}
d['version']=(ord(s[0]) & 0xf0) >> 4
d['header_len']=ord(s[0]) & 0x0f
d['tos']=ord(s[1])
d['total_len']=socket.ntohs(struct.unpack('H',s[2:4])[0])
d['id']=socket.ntohs(struct.unpack('H',s[4:6])[0])
d['flags']=(ord(s[6]) & 0xe0) >> 5
d['fragment_offset']=socket.ntohs(struct.unpack('H',s[6:8])[0] & 0x1f)
d['ttl']=ord(s[8])
#!/usr/bin/ruby
require 'aws-sdk'
creds = Aws::SharedCredentials.new()
ec2 = Aws::EC2::Client.new(credentials: creds, region:'eu-west-1')
sg = ec2.describe_security_groups()
sg.security_groups.each do |x|
puts(x.group_id)
end

Keybase proof

I hereby claim:

  • I am irishsmurf on github.
  • I am paddez (https://keybase.io/paddez) on keybase.
  • I have a public key whose fingerprint is F893 B2A9 BB70 14AA E756 2D7C 1DB1 7821 6DA0 2CD1

To claim this, I am signing this object: