Giter Site home page Giter Site logo

Comments (10)

getActivity avatar getActivity commented on July 21, 2024

封装请求时,需对收集到的参数做统一加密,当涉及到文件时会转换base64编码

小伙子,你说参数加密要在 interceptArguments 做处理,这个我可以理解,但是要对文件做 base64 处理,这个就有点匪夷所思了,你为什么不直接传 base64 给框架?而是要先变成文件,然后再变成 base64,这样不是等于变相替换了参数的类型?

from easyhttp.

cnswan avatar cnswan commented on July 21, 2024

帅哥,你说的对,就是替换成加密参数,加密文件
我为什么不直接传 base64 给框架?而是要先变成文件,然后再变成 base64
因为是从图库里选的,不能选一张转一次base64吧,我的思路是选完了提交的时候一起处理,框架提供拦截参数这个位置也比较合适,一个出口,如果文件本身是base64的话这里不涉及转换

如果单独线程先转换,再提交,dialog方法可能比较繁琐,要show两次

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

小伙子,我理解文件转 base64 只能算编码,不能算加密吧?

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

不过你说的一点启发了我,不能在主线程发起网络请求,因为过程可能包含了一些耗时操作,不仅是你要做加密操作,框架内部会做一些反射操作,所以我把它放到子线程中来。

from easyhttp.

cnswan avatar cnswan commented on July 21, 2024

“小伙子,我理解文件转 base64 只能算编码,不能算加密吧?”
说错了,参数是AES,文件是base64
期待帅哥的下一个版本,感恩

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

EasyHttp-12.8.aar.zip

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

@cnswan 小伙子,问题处理了,你可以用上面的版本试一下有没有这个问题,有问题及时反馈一下。

from easyhttp.

cnswan avatar cnswan commented on July 21, 2024

image

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

EasyHttp-12.8.aar.zip

from easyhttp.

getActivity avatar getActivity commented on July 21, 2024

@cnswan 小伙子,你反馈的这两个问题,我经过核实,确实是真实存在的,目前我已经在框架内部做处理了,你可以下载上面的 aar 包做一下测试。

from easyhttp.

Related Issues (20)

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.