君たちの WordPress は shellshock 対策をしたのか!?

実質, ウワモノのPHPスクリプトで動くブログパッケージの問題ではないですけど.

Shellshock_-_Nam_'67

Troy Hunt: Everything you need to know about the Shellshock Bash bug

サーバとかよく分からず, ウワモノの WordPress のみで頑張ってる人はプラグインとかありますわ.

チェッカーとして使えます.

入れたらボタン押すだけ.

プラグインを追加_‹_新___android_ファッション通信_Σ_^A^;__—_WordPress

Shellshock_Vulnerability_Check_‹_新___android_ファッション通信_Σ_^A^;__—_WordPress

bash アップデート後にやってみたので, 問題なし.

Shellshock_Vulnerability_Check_‹_新___android_ファッション通信_Σ_^A^;__—_WordPress 2

WordPress › Shellshock Check « WordPress Plugins

詳しいことはよくわからないけど, ここらに書いてる.

CVE-2014-6271

CVE-2014-7169

サーバ内に入れる人は以下で「VULNERABLE」と表示されたらアウト, と.

ほとんど該当してるんじゃないかと思うけど.

env x='() { :;}; echo VULNERABLE' bash -c 'echo hello'

対策は, bash をアップデートするだけ.

yum update bash
apt-get install --only-upgrade bash

対策(アップデート)前だと,

# env x='() { :;}; echo VULNERABLE' bash -c 'echo hello'
VULNERABLE
hello

対策(アップデート)後だと,

# env x='() { :;}; echo VULNERABLE' bash -c 'echo hello'
hello

らしい.

環境変数から, bashコマンドを実行するようです.

ちと, さきほどのPHPで書かれたWPプラグインのコードを見てみる.

以下抜粋.

// CVE-2014-6271
$env = array('SHELL_SHOCK_TEST' => '() { :;}; echo VULNERABLE');
$desc = array(
    0 => array('pipe', 'r'),
    1 => array('pipe', 'w'),
    2 => array('pipe', 'w'),
);
$p = proc_open('bash -c "echo Test"', $desc, $pipes, null, $env);
$output = stream_get_contents($pipes[1]);
proc_close($p);
if (strpos($output, 'VULNERABLE') === false) {
    return false;
} else {
    return true;
}

// CVE-2014-7169
$desc = array(
    0 => array('pipe', 'r'),
    1 => array('pipe', 'w'),
    2 => array('pipe', 'w'),
);

$p = proc_open(
    "rm -f echo; env 'x=() { (a)=>\' bash -c \"echo date +%Y\"; cat echo", 
    $desc, $pipes, sys_get_temp_dir()
);
$output = stream_get_contents($pipes[1]);
proc_close($p);

$test = date('Y');

if (trim($output) === $test) {
    return true;
} else {
    return false;
}

true となれば, アウチサバ.

このプラグイン的には,PHPの関数「proc_open()」を使ってやってようですが, 他にもあるはず, shell 実行系の関数.

...
- system — 外部プログラムを実行し、出力を表示する
- exec() - 外部プログラムを実行する
- passthru() - 外部プログラムを実行し、未整形の出力を表示する
- popen() - プロセスへのファイルポインタをオープンする
- escapeshellcmd() - シェルのメタ文字をエスケープする
- pcntl_exec() - 現在のプロセス空間で指定したプログラムを実行する
- バックティック演算子
...

PHP: system - Manual

アプリ開発者 vs サーバ管理者で「おまえらがやれよ」とか不毛なことになったり,

大した理由もなしに, LLからshell叩くようなアプリを作ってたり.

 なお、ソースコードからのコンパイルではなく、ディストリビューターが配布しているbashパッケージを導入すれば、CVE-2014-6277/6278として報告されている脆弱性以外は影響を受けない事実を確認できたことも併せて発表している

ニュース - 「ShellShock」は公式パッチでは不十分、JPCERT/CCが追加の注意喚起:ITpro

Shellshockの影響が及ぶケースをまとめてみた - piyolog

けどまあ, それぞれ, いろいろな事情があったりして, いろんなレイヤーで対応策を知ってたほうが, きっとうまくいくだろうと.


Xcode アップデートで Android Studio から git が使えない

MacOSのアップデートの後, AndroidStudio にてこんなダイアログ.

cannot_git

Can't start Git: /usr/bin/git
Probably the path to Git executable is not valid.

見えてない?


$ which git
/usr/bin/git

権限?


$ brew doctor

Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry and just ignore them. Thanks!

Warning: You have an outdated version of /usr/bin/install_name_tool installed.
This will cause binary package installations to fail.
This can happen if you install osx-gcc-installer or RailsInstaller.
To restore it, you must reinstall OS X or restore the binary from
the OS packages.

Warning: Git could not be found in your PATH.
Homebrew uses Git for several internal functions, and some formulae use Git
checkouts instead of stable tarballs. You may want to install Git:
  brew install git

Agreeing to the Xcode/iOS license requires admin privileges, please re-run as root via sudo.

Warning: You have not agreed to the Xcode license.
Builds will fail! Agree to the license by opening Xcode.app or running:
    xcodebuild -license

Warning: Some keg-only formula are linked into the Cellar.
Linking a keg-only formula, such as gettext, into the cellar with
`brew link <formula>` will cause other formulae to detect them during
the `./configure` step. This may cause problems when compiling those
other formulae.

Binaries provided by keg-only formulae may override system binaries

git は入っているので, おもむろに


$ sudo xcodebuild -license

...
9.12    Entire Agreement; Governing Language
This Agreement constitutes the entire agreement between the parties with respect to the use of the SDK licensed hereunder and supersedes all prior understandings regarding such subject matter. This Agreement may be modified only: (a) by a written amendment signed by both parties, or (b) to the extent expressly permitted by this Agreement (for example, by Apple by written or email notice to You). Any translation of this Agreement is done for local requirements and in the event of a dispute between the English and any non-English version, the English version of this Agreement shall govern. If You are located in the province of Quebec, Canada, the following clause applies: The parties hereby confirm that they have requested that this Agreement and all related documents be drafted in English. Les parties ont exigé que le présent contrat et tous les documents connexes soient rédigés en anglais.
...

By typing 'agree' you are agreeing to the terms of the software license agreements. Type 'print' to print them or anything else to cancel, [agree, print, cancel]          

agree

$ brew update

あ, いけたわ.

Git_executed_successfully_and_Preferences


「LINEウェブストアにログインできませんでした」てうざくね?

なんかたくさんくるんだけども

20140821-142630

IPアドレスを表示してリンクになってるけど, そこにアクセスしろ, ってことに見えるけどなんか意味あるのだろうか.

IPアドレスを検索してみるとそこはインドネシア.

IPアドレス&所在地検索_IP_Geolocation_Search

IPアドレス&所在地検索 IP Geolocation Search

まあ, どちらにしろ自分ではないのはわかってる.

そして, ヘルプページにいく.

20140824-183645

第三者にログインされてない場合は, このLINEからのメッセージは来続けるのか.

「パスワード変更」を促されるけど, パスワードを変更しても, このメッセージてくるんだろ?

かんたんな文字列のパスワードを設定している人への警告にはなるのか.

ふと, 自分のスマホのIPアドレスなんだろうと, 簡単に調べてみたら, なんと Google-Proxy とか.

20140824-184711

診断くん

2013年3月6日 の記事とか, あたしは化石か.

Chrome for Androidのベータに、モバイルのChromeユーザのWeb閲覧を高速化し帯域を節約するための新機能を実装した、と発表した。それは一種のプロキシサーバ機能で、この機能をonにしておくと、ユーザのWebリクエストとそれに対するレスポンスがすべてGoogleのサーバを経由するようになり、そこでGoogleは同社のPageSpeedライブラリを使ってコンテンツを圧縮し最適化する。

Chrome for AndroidではWeb通信がGoogleのプロキシサーバを経由する - TechCrunch

正しいIPアドレスは FORWARD系の情報として表示されてる.

20140824-185349

フツーに端末で,「設定」-「端末の状態」で見れるのか.

20140824-185931

あ,

で, LINEのメッセージ止めるのはどうしたらいいんだたけか.

メールアドレスの変更しかないの?

関係者の方はご苦労様です.