Giter VIP home page Giter VIP logo

rsahandlerdemo's Introduction

RSAHandlerDemo

客户端和服务端http通讯双向认证,涉及密钥生成,加密/解密,加签/验签,密钥字符串存储到钥匙串。一流程的demo有此需求的可以看看。

方案:双向认证+防篡改解决方案 实施: 客户端和服务端http通讯双向认证,涉及密钥生成,加密/解密,加签/验签,密钥字符串存储到钥匙串。一流程的demo有此需求的可以看看。 SG 相当于token,用于和服务端通讯的。

第一步:A接口,返回服务端的公钥A1;

第二步:checkSG 判断为空跳过第二步,不为空则调B接口 :传SG,公钥A1加密,返回数据base64解密替代A1加密,用A2加签。A1公钥验签。base64解密。

第三步:generateSG C接口,传公钥B1,公钥A1加密,返回SG。A1公钥验签;B2解密.

3 天调试通了通讯双向认证。一天提取成工具类,一天集成到工程中。最后完成项目的客户端和服务端http通讯双向认证。

rsahandlerdemo's People

Contributors

muyushifang07 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.