Skip to content

Instantly share code, notes, and snippets.

View tinbotu's full-sized avatar

Akira KUMAGAI tinbotu

View GitHub Profile
Param($srcFile,$destFile)
Write-Host $srcFile
Write-Host $destFile
$srcProperty = Get-ItemProperty $srcFile
$srcctime = $srcProperty.CreationTime
$srcmtime = $srcProperty.LastWriteTime
Write-Host $srcctime
Write-Host $srcmtime
@ixs
ixs / intel_x520_patcher.py
Last active May 29, 2024 19:33
Intel x520 EEPROM Patcher allows to unlock the x520 network card to work with non-intel branded SFP modules.
#!/usr/bin/env python3
#
# Simple Intel x520 EEPROM patcher
# Modifies the EEPROM to unlock the card for non-intel branded SFP modules.
#
# Copyright 2020,2021,2022 Andreas Thienemann <andreas@bawue.net>
#
# Licensed under the GPLv3
#
# Based on research described at https://forums.servethehome.com/index.php?threads/patching-intel-x520-eeprom-to-unlock-all-sfp-transceivers.24634/
@jamieparfet
jamieparfet / macOS-mojave-iso.sh
Last active February 11, 2023 19:16
Create an ISO from the mojave installer app
#!/bin/bash
# This assumes that the ~6GB mojave installer is in the /Applications folder.
# If it's not, just open the App Store, search Mojave, and you can download the installer file from there.
hdiutil create -o /tmp/mojave.cdr -size 6g -layout SPUD -fs HFS+J
hdiutil attach /tmp/mojave.cdr.dmg -noverify -mountpoint /Volumes/install_mojave
sudo /Applications/Install\ macOS\ mojave.app/Contents/Resources/createinstallmedia --volume /Volumes/install_mojave
mv /tmp/mojave.cdr.dmg ~/Desktop/InstallSystem.dmg
hdiutil detach /Volumes/Install\ macOS\ mojave
@samymassoud
samymassoud / Macvendors.html
Last active January 11, 2021 19:29
Mac vendor lookup using https://macvendors.co JSONP API
<html>
<head>
<title>Macvendors.co JSONP API Example</title>
</head>
<body>
<div style="width:700px;margin:0 auto;">
<h2><a href="https://macvendors.co">Macvendors.co</a> JSONP API Example</h2>
@tajibot
tajibot / gist:a5456f8187ca2c8c3328
Last active August 29, 2015 14:26
WLCのアソシエート数登録
参考http://www.janog.gr.jp/meeting/janog31/LA.html
MIB
http://tools.cisco.com/Support/SNMP/do/BrowseOID.do?local=en&translate=Translate&objectInput=1.3.6.1.4.1.14179.2.2.2.1.15
例:
APのRadio MAC: 00:1f:26:2a:47:c0 →(10進数)→ 0.31.38.42.71.192 のアソシエート数MIB
119/2.4/ 1.3.6.1.4.1.14179.2.2.2.1.15.0.31.38.42.71.192.0 ←2.4GHzのアソシエート数
119/5.0/ 1.3.6.1.4.1.14179.2.2.2.1.15.0.31.38.42.71.192.1 ←5GHzのアソシエート数
# -*- coding:utf-8 -*-
import sys
import traceback
import datetime
from dateutil.parser import parse
import pytz
import json
import tweepy
@mala
mala / gist:4683033
Created January 31, 2013 13:57
UPnPの設定変更をFlashから行うやつって今でも出来んのかという話
http://www.gnucitizen.org/blog/hacking-the-interwebs/ や、この問題を取り上げてるブログ記事なんかで
Flashの仕様じゃー、とかバージョンアップしても直らないみたいなこと書かれてるのですが、
少なくとも現状、Flashで独自のリクエストヘッダ追加した上でのクロスドメインのPOSTリクエストはcrossdomain.xmlを要求するようになっています。
Flashの仕様なんでバージョンアップしても解消しないんだぜー、って書かれたままの記事が多くあるため
「えっ、そうなの?」という印象を受けてしまった。
この記事が書かれた頃には出来たようだけど、JavaScript使いからするとこの挙動は直感に反するもので、
Flashを使うことで「ユーザーの許可無く」「ブラウザ標準の機能で出来ること以上のことが出来ている」のがおかしい。
@smellman
smellman / build.sh
Created December 6, 2012 12:28
OpenSSLをiPhone向けにビルドしてみる(armv7)
# wget http://openssl.org/source/openssl-1.0.1c.tar.gz
# mkdir build config_temp tmp target
# SDKROOT=/Applications/Xcode4.4.1.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk ARCHS=armv7 BUILD_DIR=/Users/btm/tmp/openssl/build CONFIGURATION_TEMP_DIR=/Users/btm/tmp/openssl/config_temp TARGET_BUILD_DIR=/Users/btm/tmp/openssl/target PROJECT_TEMP_DIR=/Users/btm/tmp/openssl/tmp sh build.sh
#set | grep ARCH
#set -x
## Determine the appropriate openssl source path to use
## Introduced by michaeltyson, adapted to account for OPENSSL_SRC build path
# locate src archive file if present
@tinbotu
tinbotu / gist:2774849
Created May 23, 2012 12:02
aironet AP1231G-J-K9
aironet1200#sh ver
Cisco IOS Software, C1200 Software (C1200-K9W7-M), Version 12.3(8)JED1, RELEASE SOFTWARE (fc3)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2010 by Cisco Systems, Inc.
Compiled Tue 27-Apr-10 12:58 by alnguyen
ROM: Bootstrap program is C1200 boot loader
BOOTLDR: C1200 Boot Loader (C1200-BOOT-M) Version 12.3(2)JA3, RELEASE SOFTWARE (fc2)
aironet1200 uptime is 7 minutes