sauce-archives / isign

Code sign iOS applications, without proprietary Apple software or hardware
Other
757 stars 314 forks source link

UnicodeDecodeError: 'ascii' codec can't decode byte 0xcc in position 78: ordinal not in range(128) #106

Open kahyalar opened 7 years ago

kahyalar commented 7 years ago

Hi folks, i'm using isign very commonly. It works like charm! But first time I have an error. I'll post the log down there. I hope you'll help me with this. Thanks!

COMMAND: isign -c ~/.isign/certificate.pem -k ~/.isign/key.pem -p ~/.isign/isign.mobileprovision -o /Users/kahyalar/Desktop/Resigned.ipa /Users/kahyalar/Desktop/avea-oim-test.ipa


RESULT: Removing WatchKit bundle /var/folders/jp/cwnfmr9d4bq4vc5mzryt7_fc0000gn/T/isign-w5OMYx/Payload/Online İşlemler.app/PlugIns/AveaCep WatchKit Extension.appex Traceback (most recent call last): File "/usr/local/bin/isign", line 4, in import('pkg_resources').run_script('isign==1.6.15.1496998596.dev2+root', 'isign') File "/usr/local/lib/python2.7/site-packages/pkg_resources/init.py", line 739, in run_script self.require(requires)[0].run_script(script_name, ns) File "/usr/local/lib/python2.7/site-packages/pkg_resources/init.py", line 1494, in run_script exec(code, namespace, namespace) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/EGG-INFO/scripts/isign", line 190, in isign.resign(app_path, **kwargs) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/isign.py", line 76, in resign info_props) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/archive.py", line 395, in resign ua.bundle.resign(signer, provisioning_profile) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/bundle.py", line 240, in resign super(App, self).resign(signer) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/bundle.py", line 167, in resign self.sign(signer) File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/bundle.py", line 159, in sign self.seal_path = code_resources.make_seal(self.get_executable_path(), File "/usr/local/lib/python2.7/site-packages/isign-1.6.15.1496998596.dev2+root-py2.7.egg/isign/bundle.py", line 62, in get_executable_path executable = join(self.path, executable_name) File "/usr/local/Cellar/python/2.7.13_1/Frameworks/Python.framework/Versions/2.7/lib/python2.7/posixpath.py", line 73, in join path += '/' + b UnicodeDecodeError: 'ascii' codec can't decode byte 0xcc in position 78: ordinal not in range(128)

ncc0706 commented 5 years ago

I have same problem

[root@iZj6c3erybi4j7wk1hetn6Z .isign]# isign -o my.ipa sample.ipa
Traceback (most recent call last):
  File "/usr/bin/isign", line 190, in <module>
    isign.resign(app_path, **kwargs)
  File "/usr/lib/python2.7/site-packages/isign/isign.py", line 76, in resign
    info_props)
  File "/usr/lib/python2.7/site-packages/isign/archive.py", line 395, in resign
    ua.bundle.resign(signer, provisioning_profile)
  File "/usr/lib/python2.7/site-packages/isign/bundle.py", line 240, in resign
    super(App, self).resign(signer)
  File "/usr/lib/python2.7/site-packages/isign/bundle.py", line 167, in resign
    self.sign(signer)
  File "/usr/lib/python2.7/site-packages/isign/bundle.py", line 160, in sign
    self.path)
  File "/usr/lib/python2.7/site-packages/isign/code_resources.py", line 226, in make_seal
    return write_plist(target_dir, plist)
  File "/usr/lib/python2.7/site-packages/isign/code_resources.py", line 204, in write_plist
    plistlib.writePlist(plist, fh)
  File "/usr/lib64/python2.7/plistlib.py", line 94, in writePlist
    writer.writeValue(rootObject)
  File "/usr/lib/python2.7/site-packages/isign/code_resources.py", line 32, in writeValue
    self.oldWriteValue(value)
  File "/usr/lib64/python2.7/plistlib.py", line 252, in writeValue
    self.writeDict(value)
  File "/usr/lib64/python2.7/plistlib.py", line 281, in writeDict
    self.writeValue(value)
  File "/usr/lib/python2.7/site-packages/isign/code_resources.py", line 32, in writeValue
    self.oldWriteValue(value)
  File "/usr/lib64/python2.7/plistlib.py", line 252, in writeValue
    self.writeDict(value)
  File "/usr/lib64/python2.7/plistlib.py", line 280, in writeDict
    self.simpleElement("key", key)
  File "/usr/lib64/python2.7/plistlib.py", line 172, in simpleElement
    value = _escapeAndEncode(value)
  File "/usr/lib64/python2.7/plistlib.py", line 222, in _escapeAndEncode
    return text.encode("utf-8")             # encode as UTF-8
UnicodeDecodeError: 'ascii' codec can't decode byte 0xef in position 21: ordinal not in range(128)

python version

Python 2.7.5

os

NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"

CENTOS_MANTISBT_PROJECT="CentOS-7"
CENTOS_MANTISBT_PROJECT_VERSION="7"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="7"
ncc0706 commented 5 years ago
vim /usr/bin/isign
import sys
reload(sys)  
sys.setdefaultencoding('utf8')
testcoder1 commented 5 years ago
vim /usr/bin/isign
import sys
reload(sys)  
sys.setdefaultencoding('utf8')

I did this, but it didn't work. can you help me? I need you help.