Skip to content

Instantly share code, notes, and snippets.

View st63jun's full-sized avatar

Jun SAITO st63jun

View GitHub Profile

Keybase proof

I hereby claim:

  • I am st63jun on github.
  • I am st63jun (https://keybase.io/st63jun) on keybase.
  • I have a public key whose fingerprint is 4586 4CFE DF74 CC44 CC57 4653 98C2 A424 F1A6 2D35

To claim this, I am signing this object:

@st63jun
st63jun / winzip
Created November 5, 2017 03:31
Windows でも文字化けせずに開ける Zip ファイルを作るスクリプト
#!/bin/bash
#
# Windows でも文字化けせずに開ける Zip ファイルを作るスクリプト。
# convmv(1) と zip(1) と pwqgen(1) が必要です。
#
# SYNOPSIS
#
# $ # 普通のZipファイルを作る
# $ winzip foo.txt
@st63jun
st63jun / amavisd-virus-sender-whitelist.patch
Created December 20, 2016 09:24
AMaViS virus sender whitelisting hack
--- /usr/sbin/amavisd.orig 2016-12-20 17:47:33.587273253 +0900
+++ /usr/sbin/amavisd 2016-12-20 18:18:18.257693185 +0900
@@ -13926,7 +13926,8 @@
$r->recip_is_local($is_local ? 1 : 0); # canonical boolean, untainted
if (!defined($r->bypass_virus_checks)) {
my $bypassed_v = lookup2(0,$recip, ca('bypass_virus_checks_maps'));
- $r->bypass_virus_checks($bypassed_v);
+ my $whitelisted_v = lookup2(0,$sender, ca('whitelist_sender_maps'));
+ $r->bypass_virus_checks($whitelisted_v || $bypassed_v);
}
@st63jun
st63jun / jmeter-dns-test.xml
Created February 2, 2015 12:34
DNS負荷テストシナリオ
<?xml version="1.0" encoding="UTF-8"?>
<jmeterTestPlan version="1.2" properties="2.7" jmeter="2.12 r1636949">
<hashTree>
<TestPlan guiclass="TestPlanGui" testclass="TestPlan" testname="テスト計画" enabled="true">
<stringProp name="TestPlan.comments"></stringProp>
<boolProp name="TestPlan.functional_mode">false</boolProp>
<boolProp name="TestPlan.serialize_threadgroups">false</boolProp>
<elementProp name="TestPlan.user_defined_variables" elementType="Arguments" guiclass="ArgumentsPanel" testclass="Arguments" testname="ユーザー定義変数" enabled="true">
<collectionProp name="Arguments.arguments"/>
</elementProp>
@st63jun
st63jun / switch-ruby
Last active August 29, 2015 14:01
switch-ruby
#!/bin/bash
#
# switch-ruby - Simple Ruby switcher
#
# The MIT License (MIT)
#
# Copyright (c) 2014 Jun SAITO <jun.saito@u-cast.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
@st63jun
st63jun / ipa_security_alert.yml
Last active December 31, 2015 14:59
IPAの重要なセキュリティ情報の新着フィードをChatWorkにポスト
global:
timezone: Asia/Tokyo
cache:
base: /tmp
log:
level: info
plugins:
- module: SubscriptionFeed
config:
@st63jun
st63jun / chat_work.rb
Created December 17, 2013 11:24
Automatic::Plugin::Publish::ChatWork
# -*- coding: utf-8 -*-
# Name:: Automatic::Plugin::Publish::ChatWork
# Author:: Jun Saito <http://github.com/st63jun>
# Created:: Dec 17, 2013
# Updated:: Dec 17, 2013
# Copyright:: Copyright (c) 2013 Jun Saito.
# License:: Licensed under the GNU GENERAL PUBLIC LICENSE, Version 3.0.
module Automatic::Plugin
require 'chatwork'
@st63jun
st63jun / format.rb
Created December 17, 2013 11:22
Automatic::Plugin::FIlter::Format
# -*- coding: utf-8 -*-
# Name:: Automatic::Plugin::Filter::Format
# Author:: Jun Saito <https://github.com/st63jun>
# Created:: Dec 17, 2013
# Updated:: Dec 17, 2013
# Copyright:: Copyright (c) 2013 Jun Saito.
# License:: Licensed under the GNU GENERAL PUBLIC LICENSE, Version 3.0.
module Automatic::Plugin
class FilterFormat
@st63jun
st63jun / kill_ja_softuses_com.user.js
Last active December 31, 2015 03:18
Googleの検索結果から ja.softuses.com を消すユーザースクリプト
// ==UserScript==
// @name Kill ja.softuses.com
// @namespace https://gist.github.com/st63jun/7926169
// @description Googleの検索結果から ja.softuses.com を無慈悲に削除
// @include https://www.google.co.jp/*
// @include https://www.google.com/*
// @include https://encrypted.google.com/*
// @version 1
// @grant none
// ==/UserScript==
@st63jun
st63jun / .gitignore
Created November 15, 2013 11:17
.gitignore for WordPress Project
.htaccess
wp-content/uploads/
wp-content/blogs.dir/
wp-content/upgrade/
wp-content/backup-db/
wp-content/advanced-cache.php
wp-content/wp-cache-config.php
sitemap.xml
*.log
wp-content/cache/