分类 资料 下的文章

送idea正版激活码一枚

idea15及以上可用

有效时间是2016年2月26日至2017年2月25日

激活码仅可用于教育

43B4A73YYJ-eyJsaWNlbnNlSWQiOiI0M0I0QTczWVlKIiwibGljZW5zZWVOYW1lIjoibGFuIHl1IiwiYXNzaWdu
ZWVOYW1lIjoiIiwiYXNzaWduZWVFbWFpbCI6IiIsImxpY2Vuc2VSZXN0cmljdGlvbiI6IkZvciBl
ZHVjYXRpb25hbCB1c2Ugb25seSIsImNoZWNrQ29uY3VycmVudFVzZSI6ZmFsc2UsInByb2R1Y3Rz
IjpbeyJjb2RlIjoiSUkiLCJwYWlkVXBUbyI6IjIwMTctMDItMjUifSx7ImNvZGUiOiJBQyIsInBh
aWRVcFRvIjoiMjAxNy0wMi0yNSJ9LHsiY29kZSI6IkRQTiIsInBhaWRVcFRvIjoiMjAxNy0wMi0y
NSJ9LHsiY29kZSI6IlBTIiwicGFpZFVwVG8iOiIyMDE3LTAyLTI1In0seyJjb2RlIjoiRE0iLCJw
YWlkVXBUbyI6IjIwMTctMDItMjUifSx7ImNvZGUiOiJDTCIsInBhaWRVcFRvIjoiMjAxNy0wMi0y
NSJ9LHsiY29kZSI6IlJTMCIsInBhaWRVcFRvIjoiMjAxNy0wMi0yNSJ9LHsiY29kZSI6IlJDIiwi
cGFpZFVwVG8iOiIyMDE3LTAyLTI1In0seyJjb2RlIjoiUEMiLCJwYWlkVXBUbyI6IjIwMTctMDIt
MjUifSx7ImNvZGUiOiJSTSIsInBhaWRVcFRvIjoiMjAxNy0wMi0yNSJ9LHsiY29kZSI6IldTIiwi
cGFpZFVwVG8iOiIyMDE3LTAyLTI1In0seyJjb2RlIjoiREIiLCJwYWlkVXBUbyI6IjIwMTctMDIt
MjUifSx7ImNvZGUiOiJEQyIsInBhaWRVcFRvIjoiMjAxNy0wMi0yNSJ9XSwiaGFzaCI6IjMzOTgy
OTkvMCIsImdyYWNlUGVyaW9kRGF5cyI6MCwiYXV0b1Byb2xvbmdhdGVkIjpm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YDVQQDDA1KZXRQcm9maWxlIENB
ggkA0myxg7KDeeEwEwYDVR0lBAwwCgYIKwYBBQUHAwEwCwYDVR0PBAQDAgWgMA0GCSqGSIb3DQEB
CwUAA4ICAQC9WZuYgQedSuOc5TOUSrRigMw4/+wuC5EtZBfvdl4HT/8vzMW/oUlIP4YCvA0XKyBa
CJ2iX+ZCDKoPfiYXiaSiH+HxAPV6J79vvouxKrWg2XV6ShFtPLP+0gPdGq3x9R3+kJbmAm8w+FOd
lWqAfJrLvpzMGNeDU14YGXiZ9bVzmIQbwrBA+c/F4tlK/DV07dsNExihqFoibnqDiVNTGombaU2d
Dup2gwKdL81ua8EIcGNExHe82kjF4zwfadHk3bQVvbfdAwxcDy4xBjs3L4raPLU3yenSzr/OEur1
+jfOxnQSmEcMXKXgrAQ9U55gwjcOFKrgOxEdek/Sk1VfOjvS+nuM4eyEruFMfaZHzoQiuw4IqgGc
45ohFH0UUyjYcuFxxDSU9lMCv8qdHKm+wnPRb0l9l5vXsCBDuhAGYD6ss+Ga+aDY6f/qXZuUCEUO
H3QUNbbCUlviSz6+GiRnt1kA9N2Qachl+2yBfaqUqr8h7Z2gsx5LcIf5kYNsqJ0GavXTVyWh7PYi
KX4bs354ZQLUwwa/cG++2+wNWP+HtBhVxMRNTdVhSm38AknZlD+PTAsWGu9GyLmhti2EnVwGybSD
2Dxmhxk3IPCkhKAK+pl0eWYGZWG3tJ9mZ7SowcXLWDFAk0lRJnKGFMTggrWjV8GYpw5bq23VmIqq
DLgkNzuoog==

go get 使用代理

使用go get从golang.org下载一个包,怎么也下载不下来,发现是网络原因,这里记录下go get使用代理的方法

go get -v golang.org/x/mobile/cmd/gomobile

-v参数可以看下载的细节

set http_proxy=http://127.0.0.1:1080
set https_proxy=http://127.0.0.1:1080

这句是使用本地http代理,端口为1080

然后

go get -v golang.org/x/mobile/cmd/gomobile

就可以成功了

RSA破解算法研究的一些心得

最近研究RSA破解算法,找了大量资料,得到一些心得,这里记录下。
1、RSA算法有公钥和私钥,一般资料上都是数字来举例,实际看见的有字母,这里要注意下资料上的是10进制,实际是16进制。
2、公钥和私钥是一对,一个私钥对应一个公钥,用公钥可以计算出私钥,用私钥可以计算出公钥,不过用私钥计算公钥的计算量比用公钥计算私钥的计算量小。
3、公钥本身也是一对,私钥本身也是一对的,公钥(n,e),私钥(n,d),其中n=pq,p和q是互不相等的质数,令t=(p-1)(q-1),有p和q了就可以计算出n,e是自己选的,一般是用的65537(16进制10001),e需要和t互质,且1<e<t,然后公式ed%t=1,这里e和t是已知的,解出一个d就可以了。
4、知道怎么用p、q生成公钥、私钥了,那么现在就知道了破解RSA算法的方法了,把公钥中的n拿来分解质因数,就可以得到p、q,然后就可以计算出私钥了。

补充:公钥和私钥区分并不明显,公钥加密用私钥解密,私钥加密的用公钥解密。

下面是我用python写的代码,测试了些简单的,可以很快计算出,代码用的python 3





- 阅读剩余部分 -

分享个学优网(gkstk.com)账号密码

邮箱:bloglanyuscom@yopmail.com
手机号:18890088888
密码:bloglanyuscom
以前高中的时候经常用的网站,现在没用了,账号是用一个钻石号开的子账号,貌似必须要四川的IP才行,用的时候可能需要挂代理

android 调用shell命令

网上找了好多都不能用,最后群里一朋友给了段代码可以用,记录下

public String exec(String xx) {
    Runtime ex = Runtime.getRuntime();
    String cmdBecomeSu = "/system/bin/sh -";
    String script = xx;
    try
    {
        java.lang.Process runsum = ex.exec(cmdBecomeSu);
        int exitVal = 0;
        final OutputStreamWriter out = new OutputStreamWriter(runsum.getOutputStream());
        BufferedReader in = new BufferedReader(new InputStreamReader(runsum.getInputStream()));
        out.write(script);
        out.write("\n");
        out.flush();
        out.write("exit\n");
        out.flush();
        out.close();
        String s = "";
        String line = null;
        while ((line = in.readLine()) != null) {
            s += line + "\n";
        }
        in.close();
        exitVal = runsum.waitFor();
        if (exitVal == 0)
        {
            Log.e("Debug", "Successfully to shell");
            return s;
        }
    }
    catch ( Exception e)
    {
        Log.e("Debug", "Fails to shell");
    }
    return cmdBecomeSu;
}