Python-Noob: Versuche MEAnalyzer unter cygwin zu installieren.

Wenn du dir nicht sicher bist, in welchem der anderen Foren du die Frage stellen sollst, dann bist du hier im Forum für allgemeine Fragen sicher richtig.
Antworten
floogy
User
Beiträge: 5
Registriert: Samstag 9. November 2019, 16:17

Hallo, ich bin komplett neu hier, 54 Jahre alt, eigentlich auch mit python, obwohl es wegen linux und nun auch raspberry pi immer mal wieder Berührungspunkte gab.

Ich nutze seit Jahren Linux, meist debian oder ubuntu, habe aber auch geringe Erfahrungen mit anderen Distros, oder auch unices wie FreeBSD, Solaris, OpenIndiana oder FreeNAS. Außerdem arbeitete ich mit Mac OSX und DOS/Windows. Allerdings bin ich kein richtiger Programmierer, obwohl ich schon einiges in bash/awk/sed oder html/css/javascript/php gescriptet habe, aber nicht sonderlich strukturiert.

Nun habe ich das Problem, dass seit dem Umstieg auf Windows 10 die Intel Management-Engine ME nicht mehr unterstützt wird. Ich habe die Version 8.1.71.3608, die laut https://www.win-raid.com/t596f39-Intel- ... Tools.html eventuell upgradeable bis v9.1 oder sogar v10.05 (IvyBridge) sein könnte, je nach BIOS(?). Daher frage ich mich, ob es vielleicht möglich wäre mit dem MEAnalyzer, einem Python-Script die benötigten Infos auszulesen.
A. About ME Analyzer

ME Analyzer is a tool which parses Intel Engine & PMC firmware images from the (Converged Security) Management Engine, (Converged Security) Trusted Execution Engine, (Converged Security) Server Platform Services & Power Management Controller families. It can be used by end-users who are looking for all relevant firmware information such as Family, Version, Release, Type, Date, SKU, Platform etc. It is capable of detecting new/unknown firmware, checking firmware health, Updated/Outdated status and many more. ME Analyzer is also a powerful Engine firmware research analysis tool with multiple structures which allow, among others, full parsing and unpacking of Converged Security Engine (CSE) code & file system, Flash Partition Table (FPT), Boot Partition Descriptor Table (BPDT/IFWI), CSE Layout Table (LT), advanced Size detection etc. Moreover, with the help of its extensive database, ME Analyzer is capable of uniquely categorizing all supported Engine firmware as well as check for any firmware which have not been stored at the Intel Engine Firmware Repositories yet.
https://github.com/platomav/MEAnalyzer

Meine Systemvoraussetzungen

Code: Alles auswählen

Mainboard: Gigabyte Technology Co., Ltd. Q77M-D2H
CPU: Intel(R) Core(TM) i5-3475S CPU @ 2.90GHz
OS: Microsoft Windows 10, 10.0 1903, Build 18362
cygwin 3.0.7
GNU bash, Version 4.4.12(3)-release (x86_64-unknown-cygwin)
Python 3.6.9 (default, Jul 21 2019, 14:33:59) [GCC 7.4.0]
Intel ® Management Engine 8.1.71.3608 
Mesh Commander v0.7.4
MeshCentral 2.0 beta 2 @raspberi pi3 B+, on raspbian  GNU/Linux 9.11 (stretch)
Cygwin und Python-Voraussetzungen

Code: Alles auswählen

floogy@cygwin ~/MEAnalyzer
$ cygcheck -s

Cygwin Configuration Diagnostics
Current System Time: Sat Nov 09 16:07:36 2019

Windows 10 Ver 10.0 Build 18362

   Cygwin DLL version info:
        DLL version: 3.0.7
        DLL epoch: 19
        DLL old termios: 5
        DLL malloc env: 28
        Cygwin conv: 181
        API major: 0
        API minor: 338
        Shared data: 5
        DLL identifier: cygwin1
        Mount registry: 3
        Cygwin registry name: Cygwin
        Installations name: Installations
        Cygdrive default prefix:
        Build date:
        Shared id: cygwin1S5

  437k 2018/05/24 C:\cygwin64\lib\lapack\cygblas-0.dll
 6901k 2018/05/24 C:\cygwin64\lib\lapack\cyglapack-0.dll

No Cygwin services found.


floogy@cygwin ~/MEAnalyzer
$ cygcheck -s | grep ^python3
python3                              3.6.8-1                          OK
python3-test                         3.6.8-1                          OK
python3-tkinter                      3.6.8-1                          OK
python36                             3.6.9-1                          OK
python36-cffi                        1.12.2-1                         OK
python36-chardet                     3.0.4-1                          OK
python36-doc                         3.6.8-1                          OK
python36-imaging                     5.4.1-1                          OK
python36-olefile                     0.46-1                           OK
python36-ply                         3.11-1                           OK
python36-pycparser                   2.19-1                           OK
python36-pygments                    2.3.1-1                          OK
python36-test                        3.6.9-1                          OK
python36-tkinter                     3.6.9-1                          OK


floogy@cygwin ~/MEAnalyzer
$ python3 -m pip --version
pip 18.1 from /usr/lib/python3.6/site-packages/pip (python 3.6)

Code: Alles auswählen

floogy@cygwin ~
$ pip3 install colorama
Collecting colorama
  Downloading https://files.pythonhosted.org/packages/4f/a6/728666f39bfff1719fc94c481890b2106837da9318031f71a8424b662e12/colorama-0.4.1-py2.py3-none-any.whl
Installing collected packages: colorama
Successfully installed colorama-0.4.1
You are using pip version 9.0.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

floogy@cygwin ~
$ pip install --upgrade pip
Collecting pip
  Downloading https://files.pythonhosted.org/packages/00/b6/9cfa56b4081ad13874b0c6f96af8ce16cfbc1cb06bedf8e9164ce5551ec1/pip-19.3.1-py2.py3-none-any.whl (1.4MB)
    100% |████████████████████████████████| 1.4MB 701kB/s
Installing collected packages: pip
  Found existing installation: pip 9.0.1
    Uninstalling pip-9.0.1:
      Successfully uninstalled pip-9.0.1
Successfully installed pip-19.3.1

floogy@cygwin ~
$ pip3 install colorama
Requirement already satisfied: colorama in /usr/lib/python3.6/site-packages (0.4.1)

floogy@cygwin ~
$ pip3 install crccheck
Collecting crccheck
  Downloading https://files.pythonhosted.org/packages/2f/43/91b22ee387b9323eb0be0c6cbf266e010c69e5a98db45aa3bf30c9f2388d/crccheck-0.6.zip
Building wheels for collected packages: crccheck
  Building wheel for crccheck (setup.py) ... done
  Created wheel for crccheck: filename=crccheck-0.6-cp36-none-any.whl size=19061 sha256=6c2efbd86c6696dc22cf268a894c138c2165ffb02f7bfe85970e1bb1831299f6
  Stored in directory: /home/Gerhard/.cache/pip/wheels/e7/e0/63/db7a386032c204d1e6508a4e4b735b2c410349e21cf31990bb
Successfully built crccheck
Installing collected packages: crccheck
Successfully installed crccheck-0.6

floogy@cygwin ~
$ pip3 install pltable
Collecting pltable
  Downloading https://files.pythonhosted.org/packages/7e/fe/973f7789d3fecb78391ff2c5b544e45a8a27b8f8ccda3991711a024f110f/PLTable-1.0.0.tar.gz
Building wheels for collected packages: pltable
  Building wheel for pltable (setup.py) ... done
  Created wheel for pltable: filename=PLTable-1.0.0-cp36-none-any.whl size=18141 sha256=47871bd9525d15aec07f398cde3db67f8a30ec6699b7b2e4767380fab61ec871
  Stored in directory: /home/Gerhard/.cache/pip/wheels/87/8b/ec/193641db1c309f5faba0b014f8105c0d36d8f56aedc6a2a427
Successfully built pltable
Installing collected packages: pltable
Successfully installed pltable-1.0.0

floogy@cygwin ~
$ pip install --upgrade
ERROR: You must give at least one requirement to install (see "pip help install")

floogy@cygwin ~
$ python --version
Python 2.7.16

floogy@cygwin ~
$ pip3 install pyinstaller
Collecting pyinstaller
  Downloading https://files.pythonhosted.org/packages/e2/c9/0b44b2ea87ba36395483a672fddd07e6a9cb2b8d3c4a28d7ae76c7e7e1e5/PyInstaller-3.5.tar.gz (3.5MB)
     |████████████████████████████████| 3.5MB 3.1MB/s
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Collecting altgraph
  Downloading https://files.pythonhosted.org/packages/0a/cc/646187eac4b797069e2e6b736f14cdef85dbe405c9bfc7803ef36e4f62ef/altgraph-0.16.1-py2.py3-none-any.whl
Requirement already satisfied: setuptools in /usr/lib/python3.6/site-packages (from pyinstaller) (35.0.2)
Requirement already satisfied: six>=1.6.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.10.0)
Requirement already satisfied: packaging>=16.8 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (16.8)
Requirement already satisfied: appdirs>=1.4.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.4.3)
Requirement already satisfied: pyparsing in /usr/lib/python3.6/site-packages (from packaging>=16.8->setuptools->pyinstaller) (2.2.0)
Building wheels for collected packages: pyinstaller
  Building wheel for pyinstaller (PEP 517) ... error
  ERROR: Command errored out with exit status 1:
   command: /usr/bin/python3 /usr/lib/python3.6/site-packages/pip/_vendor/pep517/_in_process.py build_wheel /tmp/tmp200w80za
       cwd: /tmp/pip-install-576ye__a/pyinstaller
  Complete output (25 lines):
  running bdist_wheel
  running build
  running build_bootloader
  Setting top to                           : /tmp/pip-install-576ye__a/pyinstaller/bootloader
  Setting out to                           : /tmp/pip-install-576ye__a/pyinstaller/bootloader/build
  Python Version                           : 3.6.9 (default, Jul 21 2019, 14:33:59) [GCC 7.4.0]
  Checking for 'gcc' (C compiler)          : /usr/bin/gcc
  Traceback (most recent call last):
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 118, in waf_entry_point
      run_commands()
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 178, in run_commands
      ctx=run_command(cmd_name)
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 169, in run_command
      ctx.execute()
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Configure.py", line 85, in execute
      super(ConfigurationContext,self).execute()
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 85, in execute
      self.recurse([os.path.dirname(g_module.root_path)])
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 126, in recurse
      user_function(self)
    File "/tmp/pip-install-576ye__a/pyinstaller/bootloader/wscript", line 427, in configure
      DESTOS_TO_SYSTEM[ctx.env.DEST_OS])
  KeyError: 'cygwin'
  No precompiled bootloader found. Trying to compile it for you ...
  ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py
  ----------------------------------------
  ERROR: Failed building wheel for pyinstaller
  Running setup.py clean for pyinstaller
Failed to build pyinstaller
ERROR: Could not build wheels for pyinstaller which use PEP 517 and cannot be installed directly

I faced same error, here's what worked for me:

Run windows powershell as administrator, and downgrade pip to 18.1 by typing pip install pip==18.1 this will uninstall 19.0.1 and install 18.1 version. After that just run pip install pyinstaller and it should finish it with no errors. Than you can upgrade pip to 19.0.1 with python -m pip install –upgrade pip

Hope this help you too.

Cheers =)
https://stackoverflow.com/questions/543 ... hrough-pip

Allerdings gibt es einen weiteren Fehler:

Code: Alles auswählen

floogy@cygwin ~
$ git clone https://github.com/platomav/MEAnalyzer.git
Klone nach 'MEAnalyzer' ...
remote: Enumerating objects: 169, done.
remote: Counting objects: 100% (169/169), done.
remote: Compressing objects: 100% (143/143), done.
remote: Total 956 (delta 51), reused 139 (delta 26), pack-reused 787                  98% (
Empfange Objekte: 100% (956/956), 1.85 MiB | 73.00 KiB/s, Fertig.
Löse Unterschiede auf: 100% (591/591), Fertig.



floogy@cygwin ~
$ cd MEAnalyzer/

floogy@cygwin ~/MEAnalyzer
$ ls
Changelog.txt  FileTable.dat  Huffman.dat  LICENSE  MEA.dat  MEA.py  README.md

floogy@cygwin ~/MEAnalyzer
$ pip install pip==18.1
Collecting pip==18.1
  Downloading https://files.pythonhosted.org/packages/c2/d7/90f34cb0d83a6c5631cf71dfe64cc1054598c843a92b400e55675cc2ac37/pip-18.1-py2.py3-none-any.whl (1.3MB)
     |████████████████████████████████| 1.3MB 3.2MB/s
Installing collected packages: pip
  Found existing installation: pip 19.3.1
    Uninstalling pip-19.3.1:
      Successfully uninstalled pip-19.3.1
Successfully installed pip-18.1

floogy@cygwin ~/MEAnalyzer
$ pip3 install pip==18.1
Requirement already satisfied: pip==18.1 in /usr/lib/python3.6/site-packages (18.1)
You are using pip version 18.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

floogy@cygwin ~/MEAnalyzer
$ pip3 install pyinstaller
Collecting pyinstaller
  Using cached https://files.pythonhosted.org/packages/e2/c9/0b44b2ea87ba36395483a672fddd07e6a9cb2b8d3c4a28d7ae76c7e7e1e5/PyInstaller-3.5.tar.gz
  Installing build dependencies ... done
Requirement already satisfied: setuptools in /usr/lib/python3.6/site-packages (from pyinstaller) (35.0.2)
Collecting altgraph (from pyinstaller)
  Using cached https://files.pythonhosted.org/packages/0a/cc/646187eac4b797069e2e6b736f14cdef85dbe405c9bfc7803ef36e4f62ef/altgraph-0.16.1-py2.py3-none-any.whl
Requirement already satisfied: packaging>=16.8 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (16.8)
Requirement already satisfied: six>=1.6.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.10.0)
Requirement already satisfied: appdirs>=1.4.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.4.3)
Requirement already satisfied: pyparsing in /usr/lib/python3.6/site-packages (from packaging>=16.8->setuptools->pyinstaller) (2.2.0)
Building wheels for collected packages: pyinstaller
  Running setup.py bdist_wheel for pyinstaller ... error
  Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-e0ovtqj7/pyinstaller/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-2518i13n --python-tag cp36:
  running bdist_wheel
  running build
  running build_bootloader
  No precompiled bootloader found. Trying to compile it for you ...
  Setting top to                           : /tmp/pip-install-e0ovtqj7/pyinstaller/bootloader
  Setting out to                           : /tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/build
  Python Version                           : 3.6.9 (default, Jul 21 2019, 14:33:59) [GCC 7.4.0]
  Checking for 'gcc' (C compiler)          : /usr/bin/gcc
  Traceback (most recent call last):
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 118, in waf_entry_point
      run_commands()
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 178, in run_commands
      ctx=run_command(cmd_name)
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 169, in run_command
      ctx.execute()
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Configure.py", line 85, in execute
      super(ConfigurationContext,self).execute()
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 85, in execute
      self.recurse([os.path.dirname(g_module.root_path)])
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 126, in recurse
      user_function(self)
    File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/wscript", line 427, in configure
      DESTOS_TO_SYSTEM[ctx.env.DEST_OS])
  KeyError: 'cygwin'
  ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py

  ----------------------------------------
  Failed building wheel for pyinstaller
  Running setup.py clean for pyinstaller
Failed to build pyinstaller
Installing collected packages: altgraph, pyinstaller
  Running setup.py install for pyinstaller ... error
    Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-e0ovtqj7/pyinstaller/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-np5h5wfa/install-record.txt --single-version-externally-managed --compile:
    running install
    running build
    running build_bootloader
    No precompiled bootloader found. Trying to compile it for you ...
    Setting top to                           : /tmp/pip-install-e0ovtqj7/pyinstaller/bootloader
    Setting out to                           : /tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/build
    Python Version                           : 3.6.9 (default, Jul 21 2019, 14:33:59) [GCC 7.4.0]
    Checking for 'gcc' (C compiler)          : /usr/bin/gcc
    Traceback (most recent call last):
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 118, in waf_entry_point
        run_commands()
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 178, in run_commands
        ctx=run_command(cmd_name)
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Scripting.py", line 169, in run_command
        ctx.execute()
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Configure.py", line 85, in execute
        super(ConfigurationContext,self).execute()
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 85, in execute
        self.recurse([os.path.dirname(g_module.root_path)])
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/.waf3-2.0.9-6b5f17f340ec613b295ffa3dedcecc80/waflib/Context.py", line 126, in recurse
        user_function(self)
      File "/tmp/pip-install-e0ovtqj7/pyinstaller/bootloader/wscript", line 427, in configure
        DESTOS_TO_SYSTEM[ctx.env.DEST_OS])
    KeyError: 'cygwin'
    ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py

    ----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-e0ovtqj7/pyinstaller/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-np5h5wfa/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-e0ovtqj7/pyinstaller/
You are using pip version 18.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

floogy@cygwin ~/MEAnalyzer
$ python3 -m pip install -upgrade pip

Usage:
  /usr/bin/python3 -m pip install [options] <requirement specifier> [package-index-options] ...
  /usr/bin/python3 -m pip install [options] -r <requirements file> [package-index-options] ...
  /usr/bin/python3 -m pip install [options] [-e] <vcs project url> ...
  /usr/bin/python3 -m pip install [options] [-e] <local project path> ...
  /usr/bin/python3 -m pip install [options] <archive url/path> ...

no such option: -u

floogy@cygwin ~/MEAnalyzer
$ python3 -m pip install --upgrade pip
Collecting pip
  Using cached https://files.pythonhosted.org/packages/00/b6/9cfa56b4081ad13874b0c6f96af8ce16cfbc1cb06bedf8e9164ce5551ec1/pip-19.3.1-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 18.1
    Uninstalling pip-18.1:
      Successfully uninstalled pip-18.1
Successfully installed pip-19.3.1

floogy@cygwin ~/MEAnalyzer
$ pyinstaller --noupx --onefile MEA.py
bash: pyinstaller: Kommando nicht gefunden.

floogy@cygwin ~/MEAnalyzer
$ python3 -m pyinstaller --noupx --onefile MEA.py
/usr/bin/python3: No module named pyinstaller

floogy@cygwin ~/MEAnalyzer
$ pip3 install pip==18.1
Collecting pip==18.1
  Using cached https://files.pythonhosted.org/packages/c2/d7/90f34cb0d83a6c5631cf71dfe64cc1054598c843a92b400e55675cc2ac37/pip-18.1-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 19.3.1
    Uninstalling pip-19.3.1:
      Successfully uninstalled pip-19.3.1
Successfully installed pip-18.1

floogy@cygwin ~/MEAnalyzer
$ pip3 install setuptools
Requirement already satisfied: setuptools in /usr/lib/python3.6/site-packages (35.0.2)
Requirement already satisfied: packaging>=16.8 in /usr/lib/python3.6/site-packages (from setuptools) (16.8)
Requirement already satisfied: appdirs>=1.4.0 in /usr/lib/python3.6/site-packages (from setuptools) (1.4.3)
Requirement already satisfied: six>=1.6.0 in /usr/lib/python3.6/site-packages (from setuptools) (1.10.0)
Requirement already satisfied: pyparsing in /usr/lib/python3.6/site-packages (from packaging>=16.8->setuptools) (2.2.0)
You are using pip version 18.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

Hier komme ich nicht weiter. Es liegt wohl daran, dass der bootloader nicht konfiguriert werden kann(?).

Code: Alles auswählen

[...]
    KeyError: 'cygwin'
    ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py

    ----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-e0ovtqj7/pyinstaller/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-np5h5wfa/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-e0ovtqj7/pyinstaller/
[...]
floogy
User
Beiträge: 5
Registriert: Samstag 9. November 2019, 16:17

Die Google-Suche hilft hier wohl eher nicht weiter.


Eventuell hilft aber dieser Thread:
pyinstaller does not work on cygwin #3328
This looks like some case is missing in bootloader/wscript. Please help fixing it!
Downloading the source and building the bootloader manually as described in https://pyinstaller.readthedocs.io/en/l ... lding.html. Don't worry, it's easy :-)
https://github.com/pyinstaller/pyinstaller/issues/3328
Zuletzt geändert von floogy am Samstag 9. November 2019, 19:14, insgesamt 1-mal geändert.
Benutzeravatar
__blackjack__
User
Beiträge: 14051
Registriert: Samstag 2. Juni 2018, 10:21
Wohnort: 127.0.0.1
Kontaktdaten:

@floogy: Mir ist nicht so ganz klar was Du da eigentlich machen willst. Eine fertige EXE von ME Analyzer kannst Du nicht verwenden? Letztes Release scheint das hier zu sein: https://github.com/platomav/MEAnalyzer/ ... .98.0-r180

Und falls nicht, musst Du es ja nicht unbedingt selbst in eine EXE verpacken, also den ”Schritt” C3 aus der Anleitung *muss* man ja nicht machen.
“Vir, intelligence has nothing to do with politics!” — Londo Mollari
floogy
User
Beiträge: 5
Registriert: Samstag 9. November 2019, 16:17

Hallo, vielen Dank für die Antwort!

Ich habe die Executables tatsächlich nicht gefunden. Vielen Dank also für die Verlinkung!

Auch Danke für den Hinweis, dass ich das nicht unbedingt über den Weg installieren muss, oder etwa doch?

Code: Alles auswählen

floogy@cygwin ~/MEAnalyzer
$ python3 MEA.py

Error: Unsupported platform "cygwin"!

Press enter to exit

floogy@cygwin ~/MEAnalyzer
$ python3 pyinstaller
python3: can't open file 'pyinstaller': [Errno 2] No such file or directory

Press enter to exit

floogy@cygwin ~/MEAnalyzer
$ python3 -m pyinstaller
/usr/bin/python3: No module named pyinstaller
Was denkst Du denn, wie ich trotzdem den pyinstaller installiert oder gängig bekomme?

python3 -m pip install pyinstaller

Code: Alles auswählen

$ python3 -m pip install pyinstaller
Collecting pyinstaller
  Using cached https://files.pythonhosted.org/packages/e2/c9/0b44b2ea87ba36395483a672fddd07e6a9cb2b8d3c4a28d7ae76c7e7e1e5/PyInstaller-3.5.tar.gz
  Installing build dependencies ... done
Requirement already satisfied: setuptools in /usr/lib/python3.6/site-packages (from pyinstaller) (35.0.2)
Requirement already satisfied: altgraph in /usr/lib/python3.6/site-packages (from pyinstaller) (0.16.1)
Requirement already satisfied: appdirs>=1.4.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.4.3)
Requirement already satisfied: packaging>=16.8 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (16.8)
Requirement already satisfied: six>=1.6.0 in /usr/lib/python3.6/site-packages (from setuptools->pyinstaller) (1.10.0)
Requirement already satisfied: pyparsing in /usr/lib/python3.6/site-packages (from packaging>=16.8->setuptools->pyinstaller) (2.2.0)
Building wheels for collected packages: pyinstaller
  Running setup.py bdist_wheel for pyinstaller ... error
[...]
  KeyError: 'cygwin'
  ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py

  ----------------------------------------
  Failed building wheel for pyinstaller
  Running setup.py clean for pyinstaller
Failed to build pyinstaller
Installing collected packages: pyinstaller
[...]

    KeyError: 'cygwin'
    ERROR: Failed compiling the bootloader. Please compile manually and rerun setup.py

    ----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-6ncrt__z/pyinstaller/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-etm0nc9f/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-6ncrt__z/pyinstaller/
You are using pip version 18.1, however version 19.3.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Benutzeravatar
__blackjack__
User
Beiträge: 14051
Registriert: Samstag 2. Juni 2018, 10:21
Wohnort: 127.0.0.1
Kontaktdaten:

@floogy: `MEA.py` prüft am Anfang die Plattform und Cygwin ist nicht unter denen die es ”kennt”. Ob das jetzt bedeutet das es damit tatsächlich nicht läuft weiss ich nicht, aber wieso überhaupt Cygwin?
“Vir, intelligence has nothing to do with politics!” — Londo Mollari
floogy
User
Beiträge: 5
Registriert: Samstag 9. November 2019, 16:17

Hallo, das binary, also die exe-Datei funktioniert schon mal. Das andere probiere ich noch unter python3 unter Windows.
Cygwin, da ich es gewohnt bin das zusammen mit console2 von Marko Bozikovic zu nutzen.
floogy
User
Beiträge: 5
Registriert: Samstag 9. November 2019, 16:17

Hallo,

mit der Python-Shell komme ich noch nicht so gut klar, aber grundsätzlich funktioniert es dort, anders als unter cygwin mit dem bootloader Error, was immer das ist. Das Skript passt ja auch nicht zur Plattform. Möglicherweise kann man das ja umgehen, indem man den header anpasst. Keine Ahnung.

Code: Alles auswählen

Windows PowerShell
Copyright (C) Microsoft Corporation. Alle Rechte vorbehalten.

Lernen Sie das neue plattformübergreifende PowerShell kennen – https://aka.ms/pscore6

PS C:\Users\floogy> py
Python 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>>
KeyboardInterrupt
>>> exit
Use exit() or Ctrl-Z plus Return to exit
>>> ^Z

PS C:\Users\floogy> py install pip
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: can't open file 'install': [Errno 2] No such file or directory
PS C:\Users\floogy> py -m pip upgrade pip
ERROR: unknown command "upgrade"
PS C:\Users\floogy> py -m pip update pip
ERROR: unknown command "update"
PS C:\Users\floogy> py -m pip install pip
Requirement already satisfied: pip in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (19.2.3)
WARNING: You are using pip version 19.2.3, however version 19.3.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
PS C:\Users\floogy> py -m pip install --upgrade pip
Collecting pip
  Using cached https://files.pythonhosted.org/packages/00/b6/9cfa56b4081ad13874b0c6f96af8ce16cfbc1cb06bedf8e9164ce5551ec1/pip-19.3.1-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 19.2.3
    Uninstalling pip-19.2.3:
      Successfully uninstalled pip-19.2.3
Successfully installed pip-19.3.1
PS C:\Users\floogy> py -m pip install pip=19.2.3
ERROR: Invalid requirement: 'pip=19.2.3'
Hint: = is not a valid operator. Did you mean == ?
PS C:\Users\floogy> py -m pip install pip==19.2.3
Collecting pip==19.2.3
  Downloading https://files.pythonhosted.org/packages/30/db/9e38760b32e3e7f40cce46dd5fb107b8c73840df38f0046d8e6514e675a1/pip-19.2.3-py2.py3-none-any.whl (1.4MB)
     |████████████████████████████████| 1.4MB 3.3MB/s
Installing collected packages: pip
  Found existing installation: pip 19.3.1
    Uninstalling pip-19.3.1:
      Successfully uninstalled pip-19.3.1
  WARNING: The scripts pip.exe, pip3.8.exe and pip3.exe are installed in 'C:\Users\floogy\AppData\Local\Programs\Python\Python38\Scripts' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed pip-19.2.3
PS C:\Users\floogy> py -m pip install pyinstaller
Collecting pyinstaller
  Downloading https://files.pythonhosted.org/packages/e2/c9/0b44b2ea87ba36395483a672fddd07e6a9cb2b8d3c4a28d7ae76c7e7e1e5/PyInstaller-3.5.tar.gz (3.5MB)
     |████████████████████████████████| 3.5MB 3.3MB/s
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Requirement already satisfied: setuptools in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pyinstaller) (41.2.0)
Collecting pywin32-ctypes>=0.2.0 (from pyinstaller)
  Downloading https://files.pythonhosted.org/packages/9e/4b/3ab2720f1fa4b4bc924ef1932b842edf10007e4547ea8157b0b9fc78599a/pywin32_ctypes-0.2.0-py2.py3-none-any.whl
Collecting pefile>=2017.8.1 (from pyinstaller)
  Downloading https://files.pythonhosted.org/packages/36/58/acf7f35859d541985f0a6ea3c34baaefbfaee23642cf11e85fe36453ae77/pefile-2019.4.18.tar.gz (62kB)
     |████████████████████████████████| 71kB 4.8MB/s
Collecting altgraph (from pyinstaller)
  Downloading https://files.pythonhosted.org/packages/0a/cc/646187eac4b797069e2e6b736f14cdef85dbe405c9bfc7803ef36e4f62ef/altgraph-0.16.1-py2.py3-none-any.whl
Collecting future (from pefile>=2017.8.1->pyinstaller)
  Downloading https://files.pythonhosted.org/packages/45/0b/38b06fd9b92dc2b68d58b75f900e97884c45bedd2ff83203d933cf5851c9/future-0.18.2.tar.gz (829kB)
     |████████████████████████████████| 829kB ...
Building wheels for collected packages: pyinstaller
  Building wheel for pyinstaller (PEP 517) ... done
  Created wheel for pyinstaller: filename=PyInstaller-3.5-cp38-none-any.whl size=2877932 sha256=ef28089c33329bf9a8ab19027de5388f0696997a74674fe3ba4b6ce5795f0ab6
  Stored in directory: C:\Users\floogy\AppData\Local\pip\Cache\wheels\c6\a4\e0\d9a1c5d3d876eb0675171281c293aed80839115e2eb022e6d2
Successfully built pyinstaller
Installing collected packages: pywin32-ctypes, future, pefile, altgraph, pyinstaller
  Running setup.py install for future ... done
  Running setup.py install for pefile ... done
  WARNING: The scripts pyi-archive_viewer.exe, pyi-bindepend.exe, pyi-grab_version.exe, pyi-makespec.exe, pyi-set_version.exe and pyinstaller.exe are installed in 'C:\Users\floogy\AppData\Local\Programs\Python\Python38\Scripts' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed altgraph-0.16.1 future-0.18.2 pefile-2019.4.18 pyinstaller-3.5 pywin32-ctypes-0.2.0
WARNING: You are using pip version 19.2.3, however version 19.3.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
PS C:\Users\floogy> py -m pip install --upgrade pip
Collecting pip
  Using cached https://files.pythonhosted.org/packages/00/b6/9cfa56b4081ad13874b0c6f96af8ce16cfbc1cb06bedf8e9164ce5551ec1/pip-19.3.1-py2.py3-none-any.whl
Installing collected packages: pip
  Found existing installation: pip 19.2.3
    Uninstalling pip-19.2.3:
      Successfully uninstalled pip-19.2.3
Successfully installed pip-19.3.1
PS C:\Users\floogy> cd .\MEAnalyzer\
PS C:\Users\floogy\MEAnalyzer> ls


    Verzeichnis: C:\Users\floogy\MEAnalyzer


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       09.11.2019     20:58                .git
-a----       09.11.2019     15:46             66 .gitattributes
-a----       09.11.2019     15:46          88844 Changelog.txt
-a----       09.11.2019     15:46         381637 FileTable.dat
-a----       09.11.2019     15:46         192778 Huffman.dat
-a----       09.11.2019     15:46           2564 LICENSE
-a----       09.11.2019     15:46         207757 MEA.dat
-a----       09.11.2019     15:46         481810 MEA.py
-a----       09.11.2019     15:46          10273 README.md


PS C:\Users\floogy\MEAnalyzer> py -m MEA.py
Traceback (most recent call last):
  File "C:\Users\floogy\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "C:\Users\floogy\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "C:\Users\floogy\MEAnalyzer\MEA.py", line 22, in <module>
    import crccheck
ModuleNotFoundError: No module named 'crccheck'
PS C:\Users\floogy\MEAnalyzer> py -m pip3 install colorama
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: No module named pip3
PS C:\Users\floogy\MEAnalyzer> py -m pip install colorama
Collecting colorama
  Downloading https://files.pythonhosted.org/packages/4f/a6/728666f39bfff1719fc94c481890b2106837da9318031f71a8424b662e12/colorama-0.4.1-py2.py3-none-any.whl
Installing collected packages: colorama
Successfully installed colorama-0.4.1
PS C:\Users\floogy\MEAnalyzer> py -m pip install crccheck
Collecting crccheck
  Downloading https://files.pythonhosted.org/packages/2f/43/91b22ee387b9323eb0be0c6cbf266e010c69e5a98db45aa3bf30c9f2388d/crccheck-0.6.zip
Installing collected packages: crccheck
    Running setup.py install for crccheck ... done
Successfully installed crccheck-0.6
PS C:\Users\floogy\MEAnalyzer> py -m pip install pltable
Collecting pltable
  Downloading https://files.pythonhosted.org/packages/7e/fe/973f7789d3fecb78391ff2c5b544e45a8a27b8f8ccda3991711a024f110f/PLTable-1.0.0.tar.gz
Installing collected packages: pltable
    Running setup.py install for pltable ... done
Successfully installed pltable-1.0.0
PS C:\Users\floogy\MEAnalyzer> py -m pyinstaller -noupx -onefile MEA.py
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: No module named pyinstaller
PS C:\Users\floogy\MEAnalyzer> pyinstaller -noupx -onefile MEA.py
pyinstaller : Die Benennung "pyinstaller" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder
eines ausführbaren Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern
enthalten), und wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1
+ pyinstaller -noupx -onefile MEA.py
+ ~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (pyinstaller:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\floogy\MEAnalyzer> py -m pip install pyinstaller
Requirement already satisfied: pyinstaller in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (3.5)
Requirement already satisfied: altgraph in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pyinstaller) (0.16.1)
Requirement already satisfied: setuptools in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pyinstaller) (41.2.0)
Requirement already satisfied: pywin32-ctypes>=0.2.0 in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pyinstaller) (0.2.0)
Requirement already satisfied: pefile>=2017.8.1 in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pyinstaller) (2019.4.18)
Requirement already satisfied: future in c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages (from pefile>=2017.8.1->pyinstaller) (0.18.2)
PS C:\Users\floogy\MEAnalyzer> py -m pyinstaller -noupx -onefile MEA.py
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: No module named pyinstaller
PS C:\Users\floogy\MEAnalyzer> py pyinstaller -noupx -onefile MEA.py
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: can't open file 'pyinstaller': [Errno 2] No such file or directory
PS C:\Users\floogy\MEAnalyzer> ls


    Verzeichnis: C:\Users\floogy\MEAnalyzer


Mode                LastWriteTime         Length Name
----                -------------         ------ ----
d-----       09.11.2019     20:58                .git
d-----       09.11.2019     20:58                __pycache__
-a----       09.11.2019     15:46             66 .gitattributes
-a----       09.11.2019     15:46          88844 Changelog.txt
-a----       09.11.2019     15:46         381637 FileTable.dat
-a----       09.11.2019     15:46         192778 Huffman.dat
-a----       09.11.2019     15:46           2564 LICENSE
-a----       09.11.2019     15:46         207757 MEA.dat
-a----       09.11.2019     15:46         481810 MEA.py
-a----       09.11.2019     15:46          10273 README.md


PS C:\Users\floogy\MEAnalyzer> py #pyinstaller -noupx -onefile MEA.py
Python 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> ^Z

PS C:\Users\floogy\MEAnalyzer> py pyinstaller -noupx -onefile MEA.py
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: can't open file 'pyinstaller': [Errno 2] No such file or directory
PS C:\Users\floogy\MEAnalyzer> pyinstaller -noupx -onefile MEA.py
pyinstaller : Die Benennung "pyinstaller" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder
eines ausführbaren Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern
enthalten), und wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1
+ pyinstaller -noupx -onefile MEA.py
+ ~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (pyinstaller:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\Users\floogy> py import pyinstaller
C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: can't open file 'import': [Errno 2] No such file or directory
PS C:\Users\floogy> py import c:\users\floogy\appdata\local\programs\python\python38\lib\site-packages\pyinstaller    C:\Users\floogy\AppData\Local\Programs\Python\Python38\python.exe: can't open file 'import': [Errno 2] No such file or directory
PS C:\Users\floogy> py
Python 3.8.0 (tags/v3.8.0:fa919fd, Oct 14 2019, 19:37:50) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> pyinstaller
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name 'pyinstaller' is not defined
>>> import pyinstaller
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'pyinstaller'
>>>
Mit pyinstaller komme ich aber trotzdem nicht klar.

Code: Alles auswählen

PS C:\Users\floogy> py .\MEAnalyzer\MEA.py
╔══════════════════════════════════════════╗
║         ME Analyzer v1.98.0 r182         ║
╚══════════════════════════════════════════╝

Welcome to Intel Engine Firmware Analysis Tool

Input a file name/path or press Enter to list options


File:       None

Option(s): -?  

╔══════════════════════════════════════════╗
║         ME Analyzer v1.98.0 r182         ║
╚══════════════════════════════════════════╝

Usage: MEA [FilePath] {Options}

{Options}

-?      : Displays help & usage screen
-skip   : Skips welcome & options screen
-exit   : Skips Press enter to exit prompt
-mass   : Scans all files of a given directory
-pdb    : Writes input file DB entry to text file
-dbname : Renames input file based on unique DB name
-dfpt   : Shows $FPT, BPDT and/or CSE Layout Table headers
-unp86  : Unpacks all CSE Converged Security Engine firmware
-bug86  : Enables pausing on error during CSE unpacking
-ver86  : Enables full verbose output during CSE unpacking
-html   : Writes parsable HTML files during MEA operation
-json   : Writes parsable JSON files during MEA operation

Press enter to exit

Das mit pyinstaller würde mich sowohl bei cygwin, als auch unter Windows (powershell) doch noch nteressieren.

Vielleicht gehe ich dem morgen weiter nach.

Ich glaube ich habe mich auch in MEAnalyser vertan. Offensichtlich testet das nur die Dateien der ME Pakete aus dem Repository. vielleicht muss ich alsio dazu erst mal die Firmware extrahieren. Ich dachte das testet die installierte Firmware. Mal sehen.
Antworten