欢迎光临!
若无相欠,怎会相见

Wing IDE 5 注册机代码

0x01 序言

最近想花点时间学习Python语言,感觉Python很好玩,只要有代码文件,就可以直接运行,当然你的代码要没有错误。最开始学习python语言是两年前,还是在慕课网,后来没坚持下去,改学PHP语言,现在又开始学习Python。

0x02 IDE

我曾在网上查了一段时间究竟用什么IDE来编写Python,最终我选择了Wing IDE(当然Eric也很好),看网上很多大牛,编写代码都用text编辑器,也就是文本编辑器,反正我是没这个能力,很多函数不知道,IDE好歹有点提示,万一拼写错误,IDE可以提示出来,但是文本编辑器好像就不行了。

0x03 注册机代码及注册过程

首先下载Wing IDE,它的官方网站是 https://wingware.com/downloads ,下载pro版本,注意下面这个是Wing IDE 5的注册机代码,代码也是用Python写的,直接可以运行。先贴上代码:

import sha
import string
BASE2 = '01'
BASE10 = '0123456789'
BASE16 = '0123456789ABCDEF'
BASE30 = '123456789ABCDEFGHJKLMNPQRTVWXY'
BASE36 = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ'
BASE62 = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789abcdefghijklmnopqrstuvwxyz'
BASEMAX = string.printable
def BaseConvert(number, fromdigits, todigits, ignore_negative = True):
    """ converts a "number" between two bases of arbitrary digits
    
    The input number is assumed to be a string of digits from the
    fromdigits string (which is in order of smallest to largest
    digit). The return value is a string of elements from todigits
    (ordered in the same way). The input and output bases are
    determined from the lengths of the digit strings. Negative 
    signs are passed through.
    
    decimal to binary
    >>> baseconvert(555,BASE10,BASE2)
    '1000101011'
    
    binary to decimal
    >>> baseconvert('1000101011',BASE2,BASE10)
    '555'
    
    integer interpreted as binary and converted to decimal (!)
    >>> baseconvert(1000101011,BASE2,BASE10)
    '555'
    
    base10 to base4
    >>> baseconvert(99,BASE10,"0123")
    '1203'
    
    base4 to base5 (with alphabetic digits)
    >>> baseconvert(1203,"0123","abcde")
    'dee'
    
    base5, alpha digits back to base 10
    >>> baseconvert('dee',"abcde",BASE10)
    '99'
    
    decimal to a base that uses A-Z0-9a-z for its digits
    >>> baseconvert(257938572394L,BASE10,BASE62)
    'E78Lxik'
    
    ..convert back
    >>> baseconvert('E78Lxik',BASE62,BASE10)
    '257938572394'
    
    binary to a base with words for digits (the function cannot convert this back)
    >>> baseconvert('1101',BASE2,('Zero','One'))
    'OneOneZeroOne'
    
    """
    if not ignore_negative and str(number)[0] == '-':
        number = str(number)[1:]
        neg = 1
    else:
        neg = 0
    x = long(0)
    for digit in str(number):
        x = x * len(fromdigits) + fromdigits.index(digit)

    res = ''
    while x > 0:
        digit = x % len(todigits)
        res = todigits[digit] + res
        x /= len(todigits)

    if neg:
        res = '-' + res
    return res

def SHAToBase30(digest):
    """Convert from a hexdigest form SHA hash into a more compact and
    ergonomic BASE30 representation.  This results in a 17 'digit' 
    number."""
    tdigest = ''.join([ c for i, c in enumerate(digest) if i / 2 * 2 == i ])
    result = BaseConvert(tdigest, BASE16, BASE30)
    while len(result) < 17:
        result = '1' + result

    return result
def AddHyphens(code):
    """Insert hyphens into given license id or activation request to
    make it easier to read"""
    return code[:5] + '-' + code[5:10] + '-' + code[10:15] + '-' + code[15:]

LicenseID='CN123-12345-12345-12345'      #这里是注册码,理论上可以自定义(我没试过)
#Copy the Request Code from the dialog
RequestCode='RW514-57AHV-7T6NB-9REJJ'     #这里填写返回码
hasher = sha.new()
hasher.update(RequestCode)
hasher.update(LicenseID)
digest = hasher.hexdigest().upper()
lichash = RequestCode[:3] + SHAToBase30(digest)
lichash=AddHyphens(lichash)

#Calculate the Activation Code
data=[7,123,23,87]
tmp=0
realcode=''
for i in data:
    for j in lichash:
        tmp=(tmp*i+ord(j))&0xFFFFF
    realcode+=format(tmp,'=05X')
    tmp=0

act30=BaseConvert(realcode,BASE16,BASE30)
while len(act30) < 17:
    act30 = '1' + act30
act30='AXX'+act30
act30=AddHyphens(act30)
print "The Activation Code is: "+act30

安装好wing,打开软件,会弹出窗口。

一定要选择第三项,第一项是试用,等时间到了,还得激活。license id 填写 CN123-12345-12345-12345(注册机代码里含有,当然你也可以试试自定义,但是格式还要是这样的:xxxxx-xxxxx-xxxxx-xxxxx,但是这样做后果自负。如果你修改了注册码,别忘了在代码中也改掉),点击Continue。

打开代码文件,把request code粘贴进去,保存,然后打开命令行运行python脚本。

复制上述运行结果,即激活码,输入到相应的位置,即可激活

我们看看激活的效果图:

为防止代码复制后格式出错,特将原始注册机代码文件附上:CalcActivationCode.py

赞(0) 打赏
转载请注明:飘零博客 » Wing IDE 5 注册机代码
分享到: 更多 (0)

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

欢迎光临