{"id":255764,"date":"2015-04-22T10:01:03","date_gmt":"2015-04-22T06:01:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=255764"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=255764","title":{"rendered":"\u0428\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438 \u0440\u0430\u0441\u0448\u0438\u0444\u0440\u043e\u0432\u043a\u0430 \u2014 \u043e\u0431\u0440\u0430\u0449\u0435\u043d\u0438\u0435 \u043a API OpenSSL \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0432\u044b\u0437\u043e\u0432\u043e\u0432 JNI"},"content":{"rendered":"<p>       \u0412 \u044d\u0442\u043e\u043c \u0431\u043b\u043e\u0433\u0435 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u044e\u0442\u0441\u044f \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043f\u043e \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 Intel AES-NI \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 Android \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u0443\u044e \u0437\u0434\u0435\u0441\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e, \u0432\u044b \u0441\u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 JNI, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0435\u0435 \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435 AES-NI.<br \/>  <a name=\"habracut\"><\/a>  <\/p>\n<h2><font color=\"#0071c5\">\u041d\u043e\u0432\u044b\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430 AES (Intel AES-NI)<\/font><\/h2>\n<p>  \u0418\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 Intel AES-NI \u0431\u044b\u043b\u0438 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u044b \u0432 \u043c\u0430\u0440\u0442\u0435 2008 \u0433. \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u044f \u043d\u0430\u0431\u043e\u0440\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u044b \u044586 \u0434\u043b\u044f \u043c\u0438\u043a\u0440\u043e\u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u043e\u0432 Intel. \u0426\u0435\u043b\u044c \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u0431\u043e\u0440\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0432 \u043f\u043e\u0432\u044b\u0448\u0435\u043d\u0438\u0438 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438, \u0431\u0435\u0437\u043e\u043f\u0430\u0441\u043d\u043e\u0441\u0442\u0438 \u0438 \u044d\u043d\u0435\u0440\u0433\u043e\u044d\u0444\u0444\u0435\u043a\u0442\u0438\u0432\u043d\u043e\u0441\u0442\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0445 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0438 \u0440\u0430\u0441\u0448\u0438\u0444\u0440\u043e\u0432\u043a\u0443 \u0434\u0430\u043d\u043d\u044b\u0445 \u043f\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0443 AES.<\/p>\n<h2><font color=\"#0071c5\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 Intel AES-NI \u0432 Android<\/font><\/h2>\n<p>  \u0410\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b AES \u0432 \u0441\u043e\u0441\u0442\u0430\u0432\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL \u043f\u0440\u043e\u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043b\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0431\u043e\u043b\u0435\u0435 \u0432\u044b\u0441\u043e\u043a\u0443\u044e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 \u043d\u0430\u0442\u0438\u0432\u043d\u044b\u043c\u0438 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u0430\u043c\u0438 Java. \u041f\u0440\u0438\u0447\u0438\u043d\u0430 \u0432 \u0442\u043e\u043c, \u0447\u0442\u043e \u044d\u0442\u0430 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u0430 \u0434\u043b\u044f \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u043e\u0432 Intel \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0438 AES-NI. \u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043f\u043e\u0448\u0430\u0433\u043e\u0432\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u0430 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430 OpenSSL.<\/p>\n<p>  \u041d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 Android 4.3, \u0432 OpenSSL \u0432 AOSP \u043f\u0440\u0438\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 Intel AES-NI, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0432\u0430\u043c \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u0434 \u0441 \u043d\u0443\u0436\u043d\u043e\u0439 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0435\u0439. \u0422\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c \u0435\u0433\u043e \u0441 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0432\u0435\u0431-\u0441\u0430\u0439\u0442\u0430 \u0438 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e, \u0430 \u0437\u0430\u0442\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b *.a\/*.so \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0432 \u0432\u0430\u0448\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435. \u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u0434\u0432\u0443\u043c\u044f \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438.<\/p>\n<p>  \u0415\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u043d\u0435\u0442 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430 AOSP, \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c OpenSSL <a href=\"http:\/\/www.openssl.org\/source\/\">\u0437\u0434\u0435\u0441\u044c<\/a>. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u044e\u044e \u0432\u0435\u0440\u0441\u0438\u044e, \u0447\u0442\u043e\u0431\u044b \u0438\u0437\u0431\u0435\u0436\u0430\u0442\u044c \u0432\u0441\u0435\u0445 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0445 \u0443\u044f\u0437\u0432\u0438\u043c\u043e\u0441\u0442\u0435\u0439, \u043e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d\u043d\u044b\u0445 \u0432 \u043f\u0440\u0435\u0436\u043d\u0438\u0445 \u0432\u0435\u0440\u0441\u0438\u044f\u0445 OpenSSL. AOSP \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u0442 \u0438\u043d\u0442\u0435\u0433\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u0443\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 openssl, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u0432 \u043f\u0430\u043f\u043a\u0443 jni \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0432\u0445\u043e\u0434\u044f\u0449\u0438\u043c \u0432 \u0435\u0435 \u0441\u043e\u0441\u0442\u0430\u0432 \u043f\u0430\u043f\u043a\u0430\u043c.<br \/>  \u0415\u0441\u043b\u0438 \u0432\u044b \u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0435\u0442\u0435 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 openssl \u0434\u043b\u044f \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e\u0439 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0435.<br \/>  1. \u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434:<\/p>\n<p>  wget <a href=\"https:\/\/www.openssl.org\/source\/openssl-1.0.1j.tar.gz\">https:\/\/www.openssl.org\/source\/openssl-1.0.1j.tar.gz<\/a>.<\/p>\n<p>  2. \u041a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0439\u0442\u0435: \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 (\u043e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435, \u0447\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0437\u0430\u0434\u0430\u0442\u044c \u0434\u043b\u044f \u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u043e\u0439 NDK \u043f\u043e\u043b\u043d\u044b\u0439 \u043f\u0443\u0442\u044c \u043a \u0432\u0430\u0448\u0435\u043c\u0443 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u0443):  <\/p>\n<pre><code class=\"bash\">        export NDK=~\/android-ndk-r9d         export TOOL=arm-linux-androideabi         export NDK_TOOLCHAIN_BASENAME=${TOOLCHAIN_PATH}\/${TOOL}         export CC=$NDK_TOOLCHAIN_BASE-gcc         export CXX=$NDK_TOOLCHAIN_BASENAME-g++         export LINK=${CXX}         export LD=$NDK_TOOLCHAIN_BASENAME-ld         export AR=$NDK_TOOLCHAIN_BASENAME-ar         export STRIP=$NDK_TOOLCHAIN_BASENAME-strip         export ARCH_FLAGS=\u201d-march=armv7-a \u2013mfloat-abi=softfp \u2013mfpu=vfpv3-d16\u201d         export ARCH_LINK=\u201d-march=armv7-a \u2013Wl, --flx-cortex-a\u201d         export CPPFLAGS=\u201d${ARCH_FLAGS} \u2013fpic \u2013ffunction-sections \u2013funwind-tables \u2013fstack-protector \u2013fno-strict-aliasing \u2013finline-limited=64\u201d         export LDFLAGS=\u201d${ARCH_LINK\u201d}         export CXXFLAGS=\u201d${ ARCH_FLAGS} \u2013fpic \u2013ffunction-sections \u2013funwind-tables \u2013fstack-protector \u2013fno-strict-aliasing \u2013finline-limited=64 \u2013frtti \u2013fexceptions\u201d         cd $OPENSSL_SRC_PATH         export CC=\u201d$STANDALONE_TOOCHAIN_PATH\/bin\/i686-linux-android-gcc \u2013mtune=atome \u2013march=atom \u2013sysroot=$STANDALONE_TOOCHAIN_PATH\/sysroot\u201d       export AR=$STANDALONE_TOOCHAIN_PATH\/bin\/i686-linux-android-ar       export RANLIB=$STANDALONE_TOOCHAIN_PATH\/bin\/i686-linux-android-ranlib       .\/Configure android-x86 \u2013DOPENSSL_IA32_SSE2 \u2013DAES_ASM \u2013DVPAES_ASM       make <\/code><\/pre>\n<p>  \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u0444\u0430\u0439\u043b libcrypto.a \u043f\u043e\u044f\u0432\u0438\u0442\u0441\u044f \u0432 \u043f\u0430\u043f\u043a\u0435 \u0432\u0435\u0440\u0445\u043d\u0435\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f. \u0414\u043b\u044f \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u0430 *.so \u0432\u0432\u0435\u0434\u0438\u0442\u0435 Configure shared android-x86 ***.<br \/>  \u041f\u0440\u0438 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u0433\u043e \u043a\u043e\u0434\u0430 AOSP \u0446\u0435\u043f\u043e\u0447\u043a\u0430 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 ndk \u043d\u0435 \u043d\u0443\u0436\u043d\u0430.  <\/p>\n<pre><code class=\"bash\">      source build\/envsetiup.sh       lunch &lt;options&gt;       make \u2013j8       cd external\/openssl       mm <\/code><\/pre>\n<p>  \u041f\u0440\u0438 \u044d\u0442\u043e\u043c libcrypto.a \u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u0438 \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u0442\u0441\u044f \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 out\/host\/linux_x86\/bin.<br \/>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 OpenSSL \u0447\u0435\u0440\u0435\u0437 NDK \u0432 \u043f\u0440\u043e\u0435\u043a\u0442\u0435 Android<br \/>  \u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u043f\u0440\u043e\u0435\u043a\u0442 Android \u0434\u043b\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u0432 \u0432\u0430\u0448\u0435\u0439 \u043b\u044e\u0431\u0438\u043c\u043e\u0439 \u0441\u0440\u0435\u0434\u0435 \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438. \u0417\u0434\u0435\u0441\u044c \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043f\u0440\u0438\u043c\u0435\u0440 \u0441 Eclipse.  <\/p>\n<ol>\n<li>\u041e\u0431\u044a\u044f\u0432\u0438\u0442\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438, \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u0441 OpenSSL, \u043a\u0430\u043a native function \u0432 \u0444\u0430\u0439\u043b\u0435 Android.mk.<\/li>\n<li>\u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u043f\u0430\u043f\u043a\u0443 jni \u0432 \u0438\u0441\u0445\u043e\u0434\u043d\u043e\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435 Android.<\/li>\n<li>\u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u0437\u0430\u0440\u0430\u043d\u0435\u0435 \u0441\u043a\u043e\u043c\u043f\u0438\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043f\u0430\u043f\u043a\u0438 include \u0432\u043d\u0443\u0442\u0440\u0438 \u043f\u0430\u043f\u043a\u0438 jni.<\/li>\n<li>\u0412\u043a\u043b\u044e\u0447\u0438\u0442\u0435 \u043f\u0430\u043f\u043a\u0443 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL, \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u0443\u044e \u0432 &lt;OpenSSL source\/include\/&gt;, \u0432 \u043f\u0430\u043f\u043a\u0443 jni.<\/li>\n<li>\u0417\u0430\u0442\u0435\u043c \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u0439\u0442\u0435 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u043d\u0430\u043f\u0438\u0441\u0430\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u044e C \u0432 jni\/*.c. \u041f\u043e\u0441\u043b\u0435 \u044d\u0442\u043e\u0433\u043e \u043d\u0443\u0436\u043d\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b\u044b *.a\/*.so \u0438 \u0444\u0430\u0439\u043b \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0430 \u0432 \u043f\u0440\u043e\u0435\u043a\u0442.<\/li>\n<li>\u0417\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u0438 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e \u043d\u0430 C \u0432 \u043f\u0430\u043f\u043a\u0443 jni, \u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 android, \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 \u0448\u0430\u0433\u0435 1 \u0432 \u0432\u0438\u0434\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0439 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438.<\/li>\n<\/ol>\n<p>  \u0412 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u043c \u043d\u0438\u0436\u0435 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f, \u043a\u0430\u043a \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 OpenSSL \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0438 \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u0435\u0435 \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 java.<\/p>\n<p>  \u0421\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u0432 Eclipse \u043d\u043e\u0432\u044b\u0439 \u043f\u0440\u043e\u0435\u043a\u0442, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 EncryptFileOpenSSL. \u041b\u0438\u0431\u043e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e eclipse (\u0449\u0435\u043b\u043a\u043d\u0438\u0442\u0435 \u043f\u0440\u0430\u0432\u043e\u0439 \u043a\u043d\u043e\u043f\u043a\u043e\u0439 \u043c\u044b\u0448\u0438 \u0438\u043c\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0432 \u043e\u0431\u043e\u0437\u0440\u0435\u0432\u0430\u0442\u0435\u043b\u0435 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432), \u043b\u0438\u0431\u043e \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430 \u0441\u043e\u0437\u0434\u0430\u0439\u0442\u0435 \u043f\u0430\u043f\u043a\u0443 jni, \u0430 \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0435\u0435 \u2014 \u0434\u0432\u0435 \u0432\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0435 \u043f\u0430\u043f\u043a\u0438: pre-compiled \u0438 include.<br \/>  \u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430:  <\/p>\n<pre><code class=\"bash\">      cd &lt;workspace\/of\/Project&gt;       mkdir jni\/pre-compiled\/       mkdir jni\/include       cp $OPENSSL_PATH\/libcrypto.a jni\/pre-compiled       cp \u2013L -rf $OPENSSL_PATH\/include\/openssl jni\/include       gedit jni\/Android.mk <\/code><\/pre>\n<p>  \u0417\u0430\u0442\u0435\u043c \u0434\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u0441\u0442\u0440\u043e\u043a\u0443 \u0432 \u0444\u0430\u0439\u043b jni\/Android.mk:  <\/p>\n<pre><code class=\"cpp\">      \u2026       LOCAL_MODULE :=    static       LOCAL_SRC_FILES   :=    pre-compiled\/libcrypto.a       \u2026       LOCAL_C_INCLUDES  :=    include       LOCAL_STATIC_LIBRARIES  :=    static \u2013lcrypto       \u2026 <\/code><\/pre>\n<p>  \u0417\u0430\u0442\u0435\u043c \u043c\u043e\u0436\u043d\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0444\u0443\u043d\u043a\u0446\u0438\u0438, \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u043d\u044b\u0435 \u0432 OpenSSL, \u0434\u043b\u044f \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u0432\u0430\u0448\u0438\u0445 \u0444\u0443\u043d\u043a\u0446\u0438\u0439 encrypt\/decrypt\/SSL. \u0427\u0442\u043e\u0431\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Intel AES-NI, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u0441\u0435\u0440\u0438\u0438 EVP_*, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0438\u0436\u0435. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u0430\u043f\u043f\u0430\u0440\u0430\u0442\u043d\u044b\u0439 \u043c\u043e\u0434\u0443\u043b\u044c Intel AES-NI \u0431\u0443\u0434\u0435\u0442 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u0437\u0430\u0434\u0435\u0439\u0441\u0442\u0432\u043e\u0432\u0430\u043d \u0434\u043b\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0440\u0430\u0441\u0448\u0438\u0444\u0440\u043e\u0432\u043a\u0438 AES, \u0435\u0441\u043b\u0438 \u0426\u041f \u044d\u0442\u043e \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u043f\u0440\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u0438 \u043a\u043b\u0430\u0441\u0441\u0430 \u0434\u043b\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430 OpenSSL \u0444\u0443\u043d\u043a\u0446\u0438\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432 \u043a\u043b\u0430\u0441\u0441\u0435 *.java \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a (\u044d\u0442\u043e\u0442 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 \u0432\u0437\u044f\u0442 \u0438\u0437 \u0431\u043b\u043e\u0433\u0430 \u041a\u0440\u0438\u0441\u0442\u043e\u0444\u0435\u0440\u0430 \u0411\u0435\u0440\u0434\u0430 \u043f\u043e\u0434 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u0435\u043c <a href=\"https:\/\/software.intel.com\/en-us\/android\/articles\/sample-code-data-encryption-application\">\u041e\u0431\u0440\u0430\u0437\u0435\u0446 \u043a\u043e\u0434\u0430: \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445<\/a>).  <\/p>\n<pre><code class=\"cpp\">public long encryptFile(String encFilepath, String origFilepath) {               File fileIn = new File(origFilepath);         if (fileIn.isFile()) {                                            ret = encodeFileFromJNI(encFilepath, origFilepath);                           } else {             Log.d(TAG, &quot;ERROR*** File does not exist:&quot; + origFilepath);             seconds = -1;         }                 if (ret == -1) {             throw new IllegalArgumentException(&quot;encrypt file execution did not succeed.&quot;);         }                         }        \/* native function available from encodeFile library *\/     public native int encodeFileFromJNI(String fileOut, String fileIn);     public native void setBlocksizeFromJNI(int blocksize);     public native byte[] generateKeyFromJNI(int keysize);             \/* To load the library that encrypts (encodeFile) on application startup.      * The Package manager would have alredy unpacked the library has into \/data\/data\/com.example.openssldataencryption\/lib\/libencodeFile.so      * at installation time.      *\/     static {       System.loadLibrary(&quot;crypto&quot;);       System.loadLibrary(&quot;encodeFile&quot;);     }  <\/code><\/pre>\n<p>  \u0424\u0443\u043d\u043a\u0446\u0438\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0432 \u0444\u0430\u0439\u043b\u0435 encodeFile.cpp, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u043b\u0438 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e System.loadLibrary, \u0431\u0443\u0434\u0435\u0442 \u0442\u0430\u043a\u043e\u0439:  <\/p>\n<pre><code class=\"cpp\">int encodeFile(const char* filenameOut, const char* filenameIn) {        int ret = 0;       int filenameInSize = strlen(filenameIn)*sizeof(char)+1;       int filenameOutSize = strlen(filenameOut)*sizeof(char)+1;        char filename[filenameInSize];       char encFilename[filenameOutSize];        \/\/ create key, if it's uninitialized       int seedbytes = 1024;              memset(cKeyBuffer, 0, KEYSIZE );              if (!opensslIsSeeded) {                   if (!RAND_load_file(&quot;\/dev\/urandom&quot;, seedbytes)) {                         \/\/__android_log_print(ANDROID_LOG_ERROR, TAG, &quot;Failed to seed OpenSSL RNG&quot;);                         return -1;                   }                   opensslIsSeeded = 1;             }              if (!RAND_bytes((unsigned char *)cKeyBuffer, KEYSIZE )) {                   \/\/__android_log_print(ANDROID_LOG_ERROR, TAG, &quot;Faled to create OpenSSSL random integers: %ul&quot;, ERR_get_error);             }        strncpy(encFilename, filenameOut, filenameOutSize);       encFilename[filenameOutSize-1]=0;       strncpy(filename, filenameIn, filenameInSize);       filename[filenameInSize-1]=0;        EVP_CIPHER_CTX *e_ctx = EVP_CIPHER_CTX_new();        FILE *orig_file, *enc_file;        printf (&quot;filename: %s\\n&quot; ,filename );       printf (&quot;enc filename: %s\\n&quot; ,encFilename );       orig_file = fopen( filename, &quot;rb&quot; );       enc_file = fopen ( encFilename, &quot;wb&quot; );        unsigned char *encData, *origData;       int encData_len = 0;       int len = 0;       int bytesread = 0;        \/**      * ENCRYPT      *\/       \/\/if (!(EVP_EncryptInit_ex(e_ctx, EVP_aes_256_cbc(), NULL, key, iv ))) {     if (!(EVP_EncryptInit_ex(e_ctx, EVP_aes_256_cbc(), NULL, cKeyBuffer, iv ))) {             ret = -1;             printf( &quot;ERROR: EVP_ENCRYPTINIT_EX\\n&quot;);       }             \/\/ go through file, and encrypt       if ( orig_file != NULL ) {             origData = new unsigned char[aes_blocksize];             encData = new unsigned char[aes_blocksize+EVP_CIPHER_CTX_block_size(e_ctx)]; \/\/ potential for encryption to be 16 bytes longer than original              printf( &quot;Encoding file: %s\\n&quot;, filename);              bytesread = fread(origData, 1, aes_blocksize, orig_file);             \/\/ read bytes from file, then send to cipher             while ( bytesread ) {                     if (!(EVP_EncryptUpdate(e_ctx, encData, &len, origData, bytesread))) {                         ret = -1;                         printf( &quot;ERROR: EVP_ENCRYPTUPDATE\\n&quot;);                   }                   encData_len = len;                    fwrite(encData, 1, encData_len, enc_file );                   \/\/ read more bytes                   bytesread = fread(origData, 1, aes_blocksize, orig_file);             }             \/\/ last step encryption             if (!(EVP_EncryptFinal_ex(e_ctx, encData, &len))) {                   ret = -1;                   printf( &quot;ERROR: EVP_ENCRYPTFINAL_EX\\n&quot;);             }             encData_len = len;              fwrite(encData, 1, encData_len, enc_file );              \/\/ free cipher             EVP_CIPHER_CTX_free(e_ctx);              \/\/    close files             printf( &quot;\\t&gt;&gt;\\n&quot;);              fclose(orig_file);             fclose(enc_file);       } else {             printf( &quot;Unable to open files for encoding\\n&quot;);             ret = -1;             return ret;       }       return ret; } <\/code><\/pre>\n<p>  \u0417\u0430\u0442\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c ndk-build \u0434\u043b\u044f \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0446\u0438\u0438 \u0432 &lt;source of Application&gt;.<br \/>   <i>\/&lt;path to android-ndk7&gt;\/ndk-build APP_ABI=x86<\/i><br \/>  \u0421\u043a\u043e\u043f\u0438\u0440\u0443\u0439\u0442\u0435 \u043f\u0430\u043f\u043a\u0443 <i>\/&lt;PATH\\TO\\OPENSSL&gt;\/include\/openssl<\/i> \u0432\u043d\u0443\u0442\u0440\u044c \u043f\u0430\u043f\u043a\u0438 <i>&lt;\/PATH\\to\\PROJECT\\workspace&gt;\/jni\/<\/i>.<br \/>  \u0424\u0430\u0439\u043b\u044b *.so\/*.a \u0434\u043e\u043b\u0436\u043d\u044b \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432 <i>\/&lt;\/PATH\\to\\PROJECT\\workspace&gt;\/libs\/x86\/<\/i> \u0438\u043b\u0438 <i>\/&lt;\/PATH\\to\\PROJECT\\workspace&gt;\/libs\/armeabi\/<\/i>.<br \/>  \u0424\u0430\u0439\u043b encode.cpp, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0439 \u0434\u043b\u044f \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0440\u0430\u0441\u0448\u0438\u0444\u0440\u043e\u0432\u043a\u0438, \u0434\u043e\u043b\u0436\u0435\u043d \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0432 \u043f\u0430\u043f\u043a\u0435 <i>&lt;\/PATH\\to\\PROJECT\\workspace&gt;\/jni\/<\/i>.<\/p>\n<h2><font color=\"#0071c5\">\u0410\u043d\u0430\u043b\u0438\u0437 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u0438<\/font><\/h2>\n<p>  \u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0442 \u043f\u0440\u043e\u0430\u043d\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0426\u041f, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u0430\u043c\u044f\u0442\u0438 \u0438 \u0432\u0440\u0435\u043c\u044f, \u0437\u0430\u0442\u0440\u0430\u0447\u0435\u043d\u043d\u043e\u0435 \u043d\u0430 \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u044f. \u042d\u0442\u043e\u0442 \u0438\u0441\u0445\u043e\u0434\u043d\u044b\u0439 \u043a\u043e\u0434 \u0442\u0430\u043a\u0436\u0435 \u0432\u0437\u044f\u0442 \u0438\u0437 \u0431\u043b\u043e\u0433\u0430 \u041a\u0440\u0438\u0441\u0442\u043e\u0444\u0435\u0440\u0430 \u0411\u0435\u0440\u0434\u0430.<\/p>\n<h4><b>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0426\u041f<\/b><\/h4>\n<p>  \u041f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u043d\u0438\u0436\u0435 \u043a\u043e\u0434 \u043f\u043e\u043c\u043e\u0433\u0430\u0435\u0442 \u043f\u0440\u043e\u0447\u0435\u0441\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u043e \u0441\u0440\u0435\u0434\u043d\u0435\u0439 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0435 \u043d\u0430 \u0426\u041f, \u0445\u0440\u0430\u043d\u044f\u0449\u0438\u0435\u0441\u044f \u0432 \/proc\/stat.  <\/p>\n<pre><code class=\"cpp\">public float readCPUusage() {             try {       RandomAccessFile reader = new RandomAccessFile(&quot;\/proc\/stat&quot;, &quot;r&quot;);       String load = reader.readLine();       String[] toks = load.split(&quot; &quot;);       long idle1 = Long.parseLong(toks[5]);       long cpu1 = Long.parseLong(toks[2]) + Long.parseLong(toks[3])                               + Long.parseLong(toks[4]) + Long.parseLong(toks[6])+ Long.parseLong(toks[7]) +Long.parseLong(toks[8]);                   try {                         Thread.sleep(360);                   } catch (Exception e) {                   }                    reader.seek(0);                   load = reader.readLine();                   reader.close();                   toks = load.split(&quot; &quot;);                   long idle2 = Long.parseLong(toks[5]);                   long cpu2 = Long.parseLong(toks[2]) + Long.parseLong(toks[3])+ Long.parseLong(toks[4]) + Long.parseLong(toks[6])                         + Long.parseLong(toks[7]) + ong.parseLong(toks[8]);                   return (float) (cpu2 - cpu1) \/ ((cpu2 + idle2) - (cpu1 + idle1));             } catch (IOException ex) {                   ex.printStackTrace();             }             return 0;       } <\/code><\/pre>\n<p>  <\/p>\n<h4><b>\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u0430\u043c\u044f\u0442\u0438<\/b><\/h4>\n<p>  \u041f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u043d\u0438\u0436\u0435 \u0444\u0440\u0430\u0433\u043c\u0435\u043d\u0442 \u043a\u043e\u0434\u0430 \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b\u0439 \u043e\u0431\u044a\u0435\u043c \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438.<br \/>  Memory Info \u2014 \u044d\u0442\u043e API Android, \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0438\u0439 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438.<br \/>  \u0418\u0442\u0430\u043a,1024 \u0431\u0430\u0439\u0442\u0430 = 1 \u041a\u0411, \u0430 1024 \u041a\u0411 = 1 \u041c\u0411. \u041f\u043e\u044d\u0442\u043e\u043c\u0443, \u0447\u0442\u043e\u0431\u044b \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u0430\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u0443\u044e \u043f\u0430\u043c\u044f\u0442\u044c \u0432 \u043c\u0435\u0433\u0430\u0431\u0430\u0439\u0442\u044b: 1024*1024 == 1048576  <\/p>\n<pre><code class=\"cpp\">public long readMem(ActivityManager am) {       MemoryInfo mi = new MemoryInfo();       am.getMemoryInfo(mi);       long availableMegs = mi.availMem \/ 1048576L;       return availableMegs; } \u0410\u043d\u0430\u043b\u0438\u0437 \u0432\u0440\u0435\u043c\u0435\u043d\u0438 start = System.currentTimeMillis(); \/\/ Perform Encryption. stop = System.currentTimeMillis(); seconds = (stop - start); <\/code><\/pre>\n<p>  \u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u0441\u0432\u0435\u0434\u0435\u043d\u0438\u044f \u043e\u0431 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438 \u043a\u043e\u043c\u043f\u0438\u043b\u044f\u0442\u043e\u0440\u043e\u0432 \u0441\u043c. \u0432 \u043d\u0430\u0448\u0435\u043c <a href=\"https:\/\/software.intel.com\/en-us\/articles\/optimization-notice#opt-en\">\u0443\u0432\u0435\u0434\u043e\u043c\u043b\u0435\u043d\u0438\u0438 \u043e\u0431 \u043e\u043f\u0442\u0438\u043c\u0438\u0437\u0430\u0446\u0438\u0438<\/a>.   \t<\/p>\n<div class=\"clear\"><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/255525\/\"> http:\/\/habrahabr.ru\/post\/255525\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>       \u0412 \u044d\u0442\u043e\u043c \u0431\u043b\u043e\u0433\u0435 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u044e\u0442\u0441\u044f \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u043f\u043e \u0438\u043d\u0442\u0435\u0433\u0440\u0430\u0446\u0438\u0438 \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u0439 Intel AES-NI \u0432 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 Android \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 OpenSSL. \u0412\u044b\u043f\u043e\u043b\u043d\u0438\u0432 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u0443\u044e \u0437\u0434\u0435\u0441\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043a\u0446\u0438\u044e, \u0432\u044b \u0441\u043c\u043e\u0436\u0435\u0442\u0435 \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 JNI, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0449\u0435\u0435 \u0443\u0441\u043a\u043e\u0440\u0435\u043d\u0438\u0435 AES-NI.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-255764","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/255764","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=255764"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/255764\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=255764"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=255764"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=255764"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}