Skip to content

Instantly share code, notes, and snippets.

private static Registry<ConnectionSocketFactory> getDefaultRegistry() {
return RegistryBuilder.<ConnectionSocketFactory>create()
.register("http", PlainConnectionSocketFactory.getSocketFactory())
.register("https", SSLConnectionSocketFactory.getSocketFactory())
.build();
}
@b-wind
b-wind / 0_reuse_code.js
Last active August 29, 2015 14:23
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
$ brew update --force
fatal: Cannot update paths and switch to branch 'stable' at the same time.
Did you intend to checkout 'refs/tags/1.0.6' which can not be resolved as commit?
fatal: Needed a single revision
invalid upstream refs/tags/1.0.6
Already up-to-date.
function rgless {
less $(rg --line-number "$@" | peco | awk -F : '{print "+" $2 " " $1}')
}

Android アプリの HTTPS をデバッグする

やること

いわゆる MITM (man-in-the-middle attack) と呼ばれる攻撃手法を応用してアプリのデバッグに使う
主に(Web)デバッギングプロキシというソフトウェアを使う方法論になる

  • アプリやOSの HTTP(S) 通信を デバッギングProxy ソフトウェアを通るように設定する
  • デバッギングProxy ソフトウェアで HTTPS を復号出来る様に自前のCAをOSにインストールする
@b-wind
b-wind / temp.md
Created September 14, 2020 16:32
temp
<title>temp</title>
@b-wind
b-wind / sequenceDiagram2.md
Created September 14, 2020 16:57
sequenceDiagram2
We couldn’t find that file to show.
@b-wind
b-wind / sequenceDiagram2.svg
Created September 14, 2020 16:58
sequenceDiagram2
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@b-wind
b-wind / sequenceDiagram1.svg
Created September 14, 2020 17:01
sequenceDiagram1
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@b-wind
b-wind / sequenceDiagram1.md
Created September 14, 2020 17:12
sequenceDiagram1
sequenceDiagram
HomePageView ->> HomePageViewModel: OnClickExposures
HomePageViewModel ->> ExposureNotificationService: GetExposureCount()
ExposureNotificationService ->> UserDataModel: ExposureInformation.Count()

Note right of UserDataModel: UserDataModel::ExposureInformationに保持される 

UserDataModel -->> ExposureNotificationService: count
ExposureNotificationService --&gt;&gt; HomePageViewModel: count