Skip to content

Commit f090482

Browse files
committed
First implementation. AES+CBC
1 parent 0ec645d commit f090482

File tree

308 files changed

+74968
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

308 files changed

+74968
-0
lines changed

.classpath

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<classpath>
3+
<classpathentry kind="con" path="com.android.ide.eclipse.adt.ANDROID_FRAMEWORK"/>
4+
<classpathentry kind="con" path="com.android.ide.eclipse.adt.LIBRARIES"/>
5+
<classpathentry kind="src" path="src"/>
6+
<classpathentry kind="src" path="gen"/>
7+
<classpathentry kind="output" path="bin/classes"/>
8+
</classpath>

.project

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<projectDescription>
3+
<name>CryptoDroid</name>
4+
<comment></comment>
5+
<projects>
6+
</projects>
7+
<buildSpec>
8+
<buildCommand>
9+
<name>com.android.ide.eclipse.adt.ResourceManagerBuilder</name>
10+
<arguments>
11+
</arguments>
12+
</buildCommand>
13+
<buildCommand>
14+
<name>com.android.ide.eclipse.adt.PreCompilerBuilder</name>
15+
<arguments>
16+
</arguments>
17+
</buildCommand>
18+
<buildCommand>
19+
<name>org.eclipse.jdt.core.javabuilder</name>
20+
<arguments>
21+
</arguments>
22+
</buildCommand>
23+
<buildCommand>
24+
<name>com.android.ide.eclipse.adt.ApkBuilder</name>
25+
<arguments>
26+
</arguments>
27+
</buildCommand>
28+
</buildSpec>
29+
<natures>
30+
<nature>com.android.ide.eclipse.adt.AndroidNature</nature>
31+
<nature>org.eclipse.jdt.core.javanature</nature>
32+
</natures>
33+
</projectDescription>

.settings/org.eclipse.jdt.core.prefs

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#Sun Feb 17 18:00:06 MSK 2013
2+
eclipse.preferences.version=1
3+
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
4+
org.eclipse.jdt.core.compiler.compliance=1.6
5+
org.eclipse.jdt.core.compiler.source=1.6

AndroidManifest.xml

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
package="com.cryptodroid"
4+
android:versionCode="1"
5+
android:versionName="1.0" >
6+
7+
<uses-sdk
8+
android:minSdkVersion="9"
9+
android:targetSdkVersion="9" />
10+
11+
<application
12+
android:allowBackup="true"
13+
android:icon="@drawable/ic_launcher"
14+
android:label="@string/app_name"
15+
android:theme="@style/AppTheme" >
16+
<activity
17+
android:name="com.cryptodroid.BenchTest"
18+
android:label="@string/app_name" >
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
</manifest>

bin/AndroidManifest.xml

+26
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
package="com.cryptodroid"
4+
android:versionCode="1"
5+
android:versionName="1.0" >
6+
7+
<uses-sdk
8+
android:minSdkVersion="9"
9+
android:targetSdkVersion="9" />
10+
11+
<application
12+
android:allowBackup="true"
13+
android:icon="@drawable/ic_launcher"
14+
android:label="@string/app_name"
15+
android:theme="@style/AppTheme" >
16+
<activity
17+
android:name="com.cryptodroid.BenchTest"
18+
android:label="@string/app_name" >
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
</manifest>
Binary file not shown.
Binary file not shown.

bin/jarlist.cache

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# cache for current jar dependecy. DO NOT EDIT.
2+
# format is <lastModified> <length> <SHA-1> <path>
3+
# Encoding is UTF-8

bin/res/drawable-hdpi/ic_launcher.png

6.15 KB
Loading

bin/res/drawable-ldpi/ic_launcher.png

2.12 KB
Loading

bin/res/drawable-mdpi/ic_launcher.png

3.22 KB
Loading
9.85 KB
Loading

clean

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
sh -c "find . -name '*.class' | xargs rm -f "
2+
sh -c "find . -name '*.o.d' | xargs rm -f "
3+
sh -c "find . -name '*.o' | xargs rm -f "
4+
sh -c "find . -name '*~' | xargs rm -f "

gen/com/cryptodroid/BuildConfig.java

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/** Automatically generated file. DO NOT MODIFY */
2+
package com.cryptodroid;
3+
4+
public final class BuildConfig {
5+
public final static boolean DEBUG = true;
6+
}

gen/com/cryptodroid/R.java

+49
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
/* AUTO-GENERATED FILE. DO NOT MODIFY.
2+
*
3+
* This class was automatically generated by the
4+
* aapt tool from the resource data it found. It
5+
* should not be modified by hand.
6+
*/
7+
8+
package com.cryptodroid;
9+
10+
public final class R {
11+
public static final class attr {
12+
}
13+
public static final class drawable {
14+
public static final int ic_launcher=0x7f020000;
15+
}
16+
public static final class id {
17+
public static final int buttonStart=0x7f070001;
18+
public static final int menu_settings=0x7f070002;
19+
public static final int textViewResult=0x7f070000;
20+
}
21+
public static final class layout {
22+
public static final int activity_bench_test=0x7f030000;
23+
}
24+
public static final class menu {
25+
public static final int activity_bench_test=0x7f060000;
26+
}
27+
public static final class string {
28+
public static final int app_name=0x7f040000;
29+
public static final int hello_world=0x7f040001;
30+
public static final int menu_settings=0x7f040002;
31+
}
32+
public static final class style {
33+
/**
34+
Base application theme, dependent on API level. This theme is replaced
35+
by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
36+
37+
38+
Theme customizations available in newer API levels can go in
39+
res/values-vXX/styles.xml, while customizations related to
40+
backward-compatibility can go here.
41+
42+
*/
43+
public static final int AppBaseTheme=0x7f050000;
44+
/** Application theme.
45+
All customizations that are NOT specific to a particular API-level can go here.
46+
*/
47+
public static final int AppTheme=0x7f050001;
48+
}
49+
}

ic_launcher-web.png

54.4 KB
Loading

jni/Android.mk

+147
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,147 @@
1+
LOCAL_PATH := $(call my-dir)
2+
3+
include $(CLEAR_VARS)
4+
LOCAL_MODULE := nativecryptowrapper
5+
LOCAL_CFLAGS := -fexceptions -frtti
6+
LOCAL_SRC_FILES := nativecryptowrapper/aes_base.cpp
7+
LOCAL_STATIC_LIBRARIES := cryptopp
8+
include $(BUILD_SHARED_LIBRARY)
9+
10+
include $(CLEAR_VARS)
11+
LOCAL_MODULE := cryptopp
12+
LOCAL_CFLAGS := -fexceptions -frtti
13+
LOCAL_SRC_FILES := \
14+
cryptopp/3way.cpp \
15+
cryptopp/adler32.cpp \
16+
cryptopp/algebra.cpp \
17+
cryptopp/algparam.cpp \
18+
cryptopp/arc4.cpp \
19+
cryptopp/asn.cpp \
20+
cryptopp/authenc.cpp \
21+
cryptopp/base32.cpp \
22+
cryptopp/base64.cpp \
23+
cryptopp/basecode.cpp \
24+
cryptopp/bench.cpp \
25+
cryptopp/bench2.cpp \
26+
cryptopp/bfinit.cpp \
27+
cryptopp/blowfish.cpp \
28+
cryptopp/blumshub.cpp \
29+
cryptopp/camellia.cpp \
30+
cryptopp/cast.cpp \
31+
cryptopp/casts.cpp \
32+
cryptopp/cbcmac.cpp \
33+
cryptopp/ccm.cpp \
34+
cryptopp/channels.cpp \
35+
cryptopp/cmac.cpp \
36+
cryptopp/cpu.cpp \
37+
cryptopp/crc.cpp \
38+
cryptopp/cryptlib.cpp \
39+
cryptopp/cryptlib_bds.cpp \
40+
cryptopp/datatest.cpp \
41+
cryptopp/default.cpp \
42+
cryptopp/des.cpp \
43+
cryptopp/dessp.cpp \
44+
cryptopp/dh.cpp \
45+
cryptopp/dh2.cpp \
46+
cryptopp/dll.cpp \
47+
cryptopp/dlltest.cpp \
48+
cryptopp/dsa.cpp \
49+
cryptopp/eax.cpp \
50+
cryptopp/ec2n.cpp \
51+
cryptopp/eccrypto.cpp \
52+
cryptopp/ecp.cpp \
53+
cryptopp/elgamal.cpp \
54+
cryptopp/emsa2.cpp \
55+
cryptopp/eprecomp.cpp \
56+
cryptopp/esign.cpp \
57+
cryptopp/files.cpp \
58+
cryptopp/filters.cpp \
59+
cryptopp/fips140.cpp \
60+
cryptopp/fipsalgt.cpp \
61+
cryptopp/fipstest.cpp \
62+
cryptopp/gcm.cpp \
63+
cryptopp/gf256.cpp \
64+
cryptopp/gf2n.cpp \
65+
cryptopp/gf2_32.cpp \
66+
cryptopp/gfpcrypt.cpp \
67+
cryptopp/gost.cpp \
68+
cryptopp/gzip.cpp \
69+
cryptopp/hex.cpp \
70+
cryptopp/hmac.cpp \
71+
cryptopp/hrtimer.cpp \
72+
cryptopp/ida.cpp \
73+
cryptopp/idea.cpp \
74+
cryptopp/integer.cpp \
75+
cryptopp/iterhash.cpp \
76+
cryptopp/luc.cpp \
77+
cryptopp/mars.cpp \
78+
cryptopp/marss.cpp \
79+
cryptopp/md2.cpp \
80+
cryptopp/md4.cpp \
81+
cryptopp/md5.cpp \
82+
cryptopp/misc.cpp \
83+
cryptopp/modes.cpp \
84+
cryptopp/mqueue.cpp \
85+
cryptopp/mqv.cpp \
86+
cryptopp/nbtheory.cpp \
87+
cryptopp/network.cpp \
88+
cryptopp/oaep.cpp \
89+
cryptopp/osrng.cpp \
90+
cryptopp/panama.cpp \
91+
cryptopp/pch.cpp \
92+
cryptopp/pkcspad.cpp \
93+
cryptopp/polynomi.cpp \
94+
cryptopp/pssr.cpp \
95+
cryptopp/pubkey.cpp \
96+
cryptopp/queue.cpp \
97+
cryptopp/rabin.cpp \
98+
cryptopp/randpool.cpp \
99+
cryptopp/rc2.cpp \
100+
cryptopp/rc5.cpp \
101+
cryptopp/rc6.cpp \
102+
cryptopp/rdtables.cpp \
103+
cryptopp/regtest.cpp \
104+
cryptopp/rijndael.cpp \
105+
cryptopp/ripemd.cpp \
106+
cryptopp/rng.cpp \
107+
cryptopp/rsa.cpp \
108+
cryptopp/rw.cpp \
109+
cryptopp/safer.cpp \
110+
cryptopp/salsa.cpp \
111+
cryptopp/seal.cpp \
112+
cryptopp/seed.cpp \
113+
cryptopp/serpent.cpp \
114+
cryptopp/sha.cpp \
115+
cryptopp/shacal2.cpp \
116+
cryptopp/shark.cpp \
117+
cryptopp/sharkbox.cpp \
118+
cryptopp/simple.cpp \
119+
cryptopp/skipjack.cpp \
120+
cryptopp/socketft.cpp \
121+
cryptopp/sosemanuk.cpp \
122+
cryptopp/square.cpp \
123+
cryptopp/squaretb.cpp \
124+
cryptopp/strciphr.cpp \
125+
cryptopp/tea.cpp \
126+
cryptopp/test.cpp \
127+
cryptopp/tftables.cpp \
128+
cryptopp/tiger.cpp \
129+
cryptopp/tigertab.cpp \
130+
cryptopp/trdlocal.cpp \
131+
cryptopp/ttmac.cpp \
132+
cryptopp/twofish.cpp \
133+
cryptopp/validat1.cpp \
134+
cryptopp/validat2.cpp \
135+
cryptopp/validat3.cpp \
136+
cryptopp/vmac.cpp \
137+
cryptopp/wait.cpp \
138+
cryptopp/wake.cpp \
139+
cryptopp/whrlpool.cpp \
140+
cryptopp/winpipes.cpp \
141+
cryptopp/xtr.cpp \
142+
cryptopp/xtrcrypt.cpp \
143+
cryptopp/zdeflate.cpp \
144+
cryptopp/zinflate.cpp \
145+
cryptopp/zlib.cpp
146+
147+
include $(BUILD_STATIC_LIBRARY)

jni/Application.mk

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
APP_PLATFORM=android-9
2+
APP_STL := gnustl_static
3+
APP_ABI := armeabi armeabi-v7a x86
4+
APP_OPTIM := release

0 commit comments

Comments
 (0)