pyarmor.cli 9.2.7__tar.gz → 9.2.8__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/PKG-INFO +1 -1
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/__init__.py +1 -1
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/context.py +8 -6
- pyarmor_cli-9.2.8/pyarmor/cli/core.data.1 +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/core.data.2 +0 -0
- pyarmor_cli-9.2.8/pyarmor/cli/core.data.3 +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/default.cfg +2 -1
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/hdinfo.py +12 -1
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/merge.py +2 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/register.py +4 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/PKG-INFO +1 -1
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/setup.py +1 -1
- pyarmor_cli-9.2.7/pyarmor/cli/core.data.1 +0 -0
- pyarmor_cli-9.2.7/pyarmor/cli/core.data.3 +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/README.rst +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/__main__.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/batch.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/bootstrap.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/bug.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/command.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/config.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/docker.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/generate.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/mixer.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/model.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/plugin.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/project.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/public_capsule.zip +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/repack.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/resource.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor/cli/shell.py +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/SOURCES.txt +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/dependency_links.txt +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/entry_points.txt +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/requires.txt +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/pyarmor.cli.egg-info/top_level.txt +0 -0
- {pyarmor_cli-9.2.7 → pyarmor_cli-9.2.8}/setup.cfg +0 -0
|
@@ -743,23 +743,25 @@ class Context(object):
|
|
|
743
743
|
else:
|
|
744
744
|
host = http_proxy[i:j]
|
|
745
745
|
port = http_proxy[j+1:]
|
|
746
|
-
url = b'http://
|
|
746
|
+
url = b'http://api.dashingsoft.com'
|
|
747
747
|
return b'\x00'.join([host, port, url, header, b'\x00'])
|
|
748
748
|
|
|
749
749
|
def request_token(self, url, timeout=6.0):
|
|
750
750
|
from urllib.request import urlopen
|
|
751
751
|
|
|
752
|
-
|
|
752
|
+
parts = url.split('?', 1)
|
|
753
|
+
parts[0] = self._opts('pyarmor', 'tokurl')
|
|
754
|
+
url = '?'.join(parts)
|
|
755
|
+
|
|
756
|
+
def get_response(url):
|
|
753
757
|
try:
|
|
754
758
|
from ssl import _create_unverified_context
|
|
755
759
|
context = _create_unverified_context()
|
|
756
|
-
req = 'https://%s%s' % (host, url)
|
|
757
760
|
except Exception:
|
|
758
761
|
context = None
|
|
759
|
-
|
|
760
|
-
return urlopen(req, None, timeout, context=context)
|
|
762
|
+
return urlopen(url, None, timeout, context=context)
|
|
761
763
|
|
|
762
|
-
with get_response(
|
|
764
|
+
with get_response(url) as res:
|
|
763
765
|
return res.read()
|
|
764
766
|
|
|
765
767
|
#
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
;; Pyarmor version
|
|
4
4
|
major = 9
|
|
5
5
|
minor = 2
|
|
6
|
-
patch =
|
|
6
|
+
patch = 8
|
|
7
7
|
|
|
8
8
|
;; Compatible core version for package: pyarmor.cli.core
|
|
9
9
|
cli.core = 8.1.2
|
|
@@ -23,6 +23,7 @@ timeout = 6
|
|
|
23
23
|
regurl = https://api.dashingsoft.com/product/key/enter/%s/?
|
|
24
24
|
buyurl = https://jondy.github.io/paypal/index.html
|
|
25
25
|
docurl = https://pyarmor.readthedocs.io/{lang}/latest
|
|
26
|
+
tokurl = https://api.dashingsoft.com/product/auth/r2/
|
|
26
27
|
|
|
27
28
|
[finder]
|
|
28
29
|
recursive = 0
|
|
@@ -59,7 +59,18 @@ def main(argv):
|
|
|
59
59
|
'or harddisk name like "/dev/sda"'))
|
|
60
60
|
args = parser.parse_args(argv)
|
|
61
61
|
|
|
62
|
-
|
|
62
|
+
machid = get_hd_info(GROUP_LICENSE_MACHINE_FLAG)[1:]
|
|
63
|
+
if machid[1] == '-':
|
|
64
|
+
machid2 = machid.replace('-', 'm', 1)
|
|
65
|
+
else:
|
|
66
|
+
machid2 = get_hd_info(GROUP_LICENSE_MACHINE_FLAG)[1:]
|
|
67
|
+
|
|
68
|
+
if machid == machid2:
|
|
69
|
+
print('This device is stable device')
|
|
70
|
+
print('Machine ID: %s' % machid2)
|
|
71
|
+
else:
|
|
72
|
+
print('This device is unstable device')
|
|
73
|
+
print('Machind ID is unstable in this device')
|
|
63
74
|
|
|
64
75
|
if not args.devname:
|
|
65
76
|
print('Default Harddisk Serial Number: %s' % get_hd_info(HT_HARDDISK))
|
|
@@ -139,6 +139,8 @@ def merge_runtimes(paths, rname, output):
|
|
|
139
139
|
if not os.path.exists(rpath):
|
|
140
140
|
raise RuntimeError('no runtime package found')
|
|
141
141
|
for x in os.scandir(rpath):
|
|
142
|
+
if x.name == '__pycache__':
|
|
143
|
+
continue
|
|
142
144
|
if x.is_dir():
|
|
143
145
|
logger.info('copy runtime files "%s" to "%s"', x.name, dest)
|
|
144
146
|
shutil.copytree(x.path, os.path.join(dest, x.name))
|
|
@@ -219,6 +219,8 @@ class Register(object):
|
|
|
219
219
|
[x[7:] for x in namelist if x.startswith('tokens')]))
|
|
220
220
|
for idver in MACHFLAGS:
|
|
221
221
|
machid = self._get_machine_id(idver).decode('utf-8')
|
|
222
|
+
if machid.startswith('-'):
|
|
223
|
+
raise CliError('group license not works in unstable device')
|
|
222
224
|
logger.debug('got machine id: %s', machid)
|
|
223
225
|
name = '/'.join(['tokens', machid])
|
|
224
226
|
if name in namelist:
|
|
@@ -379,6 +381,8 @@ class Register(object):
|
|
|
379
381
|
uinfo = uname()
|
|
380
382
|
devflag = self.ctx.cfg['builder'].getint('group_device_flag', 21)
|
|
381
383
|
machid = self._get_machine_id(devflag).decode('utf-8')
|
|
384
|
+
if machid.startswith('-'):
|
|
385
|
+
raise CliError('group license not works in unstable device')
|
|
382
386
|
logger.info('current machine id is "%s"', machid)
|
|
383
387
|
tpl = Template('\n'.join([
|
|
384
388
|
'# Generated by Pyarmor $rev, $timestamp',
|
|
Binary file
|
|
Binary file
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|