Giter Site home page Giter Site logo

kuzzh / android-api-security Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wzbos/android-api-security

0.0 0.0 0.0 133 KB

🔐Android API Security(.so),安卓APP/API安全加密so库,防二次打包,防API签名破解

License: Apache License 2.0

C++ 74.25% Java 10.85% CMake 14.89%

android-api-security's Introduction

Android-API-Security

Android API Security(.so),安卓APP/API安全加密so库,防二次打包,防API签名破解

接入步骤

  • 第一步:修改 app/src/main/cpp/apisecurity-lib.cpp 文件中的内容
//此处改为你的APP签名
#define SHA1 "a8e3d91a4f77dd7ccb8d43ee5046a4b6833f4785"
//此处改为你的APP包名
#define APP_PKG "cn.wzbos.android.sample"
//此处填写API盐值
#define API_SECRET "ABC"
  • 第二步:修改 app/build.gradle 文件中的签名(测试需要,非必须)
 signingConfigs {
        release {
            keyAlias 'wzbos'
            keyPassword '123456'
            storeFile file("test.keystore")
            storePassword '123456'
        }
    }
  • 第三步:拷贝 app/build/intermediates/cmake/release/obj 文件夹下的.so文件到你的项目中libs文件夹中

依赖方式

在module级的build.gradle文件中加入以下代码

    sourceSets {
        main {
           jniLibs.srcDir 'libs'
        }
    }

    implementation project(":apisecurity")

调用示例

 //初始化
 APISecurity.init(context);
 //计算签名
 String val = "POST https://www.xxx.com/login?id=1&pwd=xxx......";
 String sign = MGAPISecurity.sign(aptStr)

android-api-security's People

Contributors

wzbos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.