感谢开源!!!

iHTCboy
Posted 4 months ago in General, viewed 383 times

留言等~

def str2key(s):
    # 对字符串解码
    b_str = base64.b64decode(s)

    if len(b_str) < 162:
        return False

    hex_str = ''

    # 按位转换成16进制
    for x in b_str:
        h = hex(ord(x))[2:]
        h = h.rjust(2, '0')
        hex_str += h

    # 找到模数和指数的开头结束位置
    m_start = 29 * 2
    e_start = 159 * 2
    m_len = 128 * 2
    e_len = 3 * 2

    modulus = hex_str[m_start:m_start + m_len]
    exponent = hex_str[e_start:e_start + e_len]

    return modulus,exponent

    appendix 1 4 months ago

    添加

    import re import json

7 Replies
  • iHTCboy
    4 months ago

    你好啊~~~

    谢谢

  • iHTCboy
    4 months ago

    @iHTCboy

    真棒!!!

  • ttt
    3 months, 3 weeks ago

    good

    qwewrwr
    

    wewrwrwe gretretre

  • ceshi111
    2 months, 3 weeks ago

    @ttt 现在 在想[

    撒撒

    撒 按时]

  • ceshi111
    2 months, 3 weeks ago

    飒飒

  • ceshi111
    2 months, 3 weeks ago

    撒按时按时

  • iHTCboy
    2 months, 1 week ago

    <!DOCTYPE html>
    <html>
    <head>
      <title>Bootstrap 实例</title>
      <meta charset="utf-8">
      <meta name="viewport" content="width=device-width, initial-scale=1">
      <link rel="stylesheet" href="https://cdn.staticfile.org/twitter-bootstrap/4.1.0/css/bootstrap.min.css">
      <script src="https://cdn.staticfile.org/jquery/3.2.1/jquery.min.js"></script>
      <script src="https://cdn.staticfile.org/popper.js/1.12.5/umd/popper.min.js"></script>
      <script src="https://cdn.staticfile.org/twitter-bootstrap/4.1.0/js/bootstrap.min.js"></script>
    </head>
    <body>
    
    <div class="container">
      <h2>背景颜色</h2>
      <p class="bg-primary text-white">重要的背景颜色。</p>
      <p class="bg-success text-white">执行成功背景颜色。</p>
      <p class="bg-info text-white">信息提示背景颜色。</p>
      <p class="bg-warning text-white">警告背景颜色</p>
      <p class="bg-danger text-white">危险背景颜色。</p>
      <p class="bg-secondary text-white">副标题背景颜色。</p>
      <p class="bg-dark text-white">深灰背景颜色。</p>
      <p class="bg-light text-dark">浅灰背景颜色。</p>
    </div>
    
    </body>
    </html>
    

Leave a Reply
NIJI APP
NIJI is a forum app built with Django

General

General discussions about Django, Python, Nijiforum etc.