LoginSignup
10
7

More than 5 years have passed since last update.

PkCrack を Mac OS X Mavericks で build する

Last updated at Posted at 2013-12-03

追記

Homebrew からインストールする方法もあります。
コメントでの情報提供に感謝 :pray:

brew install pkcrack

暗号化された ZIP ファイルに対して既知平文攻撃を行う PkCrack を Mac で build する方法を紹介します。

まずは PkCrack から source をダウンロードします。

wget http://www.unix-ag.uni-kl.de/~conrad/krypto/pkcrack/pkcrack-1.2.2.tar.gz
tar xzvf pkcrack-1.2.2.tar.gz
cd pkcrack-1.2.2/src
make

make でコケるはずです。
次のようにファイルの一部を修正します。

Makefile 2 行目

-CFLAGS=-O6 -Wall
+CFLAGS=-O4 -Wall

exfunc.c 44 行目

-#include <malloc.h>
+// #include <malloc.h>

extract.c 71 行目

-#include <malloc.h>
+// #include <malloc.h>

main.c 83 行目

-#include <malloc.h>
+// #include <malloc.h>

readhead.c 58 行目

-#include <malloc.h>
+// #include <malloc.h>

zipdecrypt.c 87 行目

-#include <malloc.h>
+// #include <malloc.h>

以上。
あとは、いつも通り make するだけ。

10
7
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
10
7