Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

Error while installing (Kali Linux 2021.2): Failed to run (wine) Python pip pefile... Exit code: 1 #440

Open
FerdinandoPH opened this issue Aug 23, 2021 · 0 comments

Comments

@FerdinandoPH
Copy link

Veil version

Latest

OS Used - all info (architecture, linux flavor, etc)

Kali Linux 2021.2

How did you install Veil? (Apt, Clone from Github, etc.)

Kali Linux's quick install (apt+setup.sh force silent)

Did you run the setup script?

Yes

Pastebin link to error you are encountering (include console actions you took prior to error)

`└─$ sudo /usr/share/veil/config/setup.sh --force --silent 1 ⨯

             Veil (Setup Script) | [Updated]: 2018-05-08

==========================================================================
[Web]: https://www.veil-framework.com/ | [Twitter]: @VeilFramework

             os = kali
      osversion = 2021.2
   osmajversion = 2021
           arch = x86_64
       trueuser = ferdinandoph

userprimarygroup = ferdinandoph
userhomedir = /home/ferdinandoph
rootdir = /usr/share/veil
veildir = /var/lib/veil
outputdir = /var/lib/veil/output
dependenciesdir = /var/lib/veil/setup-dependencies
winedir = /var/lib/veil/wine
winedrive = /var/lib/veil/wine/drive_c
gempath = Z:\var\lib\veil\wine\drive_c\Ruby187\bin\gem

[I] Kali Linux 2021.2 x86_64 detected...

[I] Silent Mode: Enabled
[I] Force Mode: Enabled

[?] Are you sure you wish to install Veil?

 Continue with installation? ([y]es/[s]ilent/[N]o): S

[*] Pulling down binary dependencies

[*] Empty folder... git cloning

Clonando en '/var/lib/veil/setup-dependencies'...
remote: Enumerating objects: 12, done.
Recibiendo objetos: 100% (12/12), 207.29 MiB | 1.58 MiB/s, listo.
remote: Total 12 (delta 0), reused 0 (delta 0), pack-reused 12
Actualizando archivos: 100% (10/10), listo.

[*] Installing Wine

[*] Already have x86 architecture added...

[*] Installing Wine 32-bit and 64-bit binaries (via APT)

[*] [ALERT]: Existing Veil Wine environment detected at: /var/lib/veil/wine

 Do you want to nuke it? ([y]es/[N]o): Y

[*] Deleting existing Veil Wine environment...

[*] Creating new Veil Wine environment in: /var/lib/veil/wine

[*] Initializing Veil's Wine environment...

0012:err:ole:marshal_object couldn't get IPSFactory buffer for interface {00000131-0000-0000-c000-000000000046}
0012:err:ole:marshal_object couldn't get IPSFactory buffer for interface {6d5140c1-7436-11ce-8034-00aa006009fa}
0012:err:ole:StdMarshalImpl_MarshalInterface Failed to create ifstub, hres=0x80004002
0012:err:ole:CoMarshalInterface Failed to marshal the interface {6d5140c1-7436-11ce-8034-00aa006009fa}, 80004002
0012:err:ole:get_local_server_stream Failed: 80004002
0014:err:ole:marshal_object couldn't get IPSFactory buffer for interface {00000131-0000-0000-c000-000000000046}
0014:err:ole:marshal_object couldn't get IPSFactory buffer for interface {6d5140c1-7436-11ce-8034-00aa006009fa}
0014:err:ole:StdMarshalImpl_MarshalInterface Failed to create ifstub, hres=0x80004002
0014:err:ole:CoMarshalInterface Failed to marshal the interface {6d5140c1-7436-11ce-8034-00aa006009fa}, 80004002
0014:err:ole:get_local_server_stream Failed: 80004002
Could not find Wine Gecko. HTML rendering will be disabled.
wine: configuration in L"/var/lib/veil/wine" has been updated.
Could not find Wine Gecko. HTML rendering will be disabled.
wine: configuration in L"/var/lib/veil/wine" has been updated.
[*] Veil Wine environment successfully created!

[*] Finished package installation

[*] Initializing (OS + Wine) Python dependencies installation...

[*] Installing (Wine) Python...

[*] Next -> Next -> Next -> Finished! ...Overwrite if prompt (use default values)

0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
0009:err:mscoree:LoadLibraryShim error reading registry key for installroot
Ignoring indexes: https://pypi.python.org/simple
Collecting setuptools
Collecting pip
Installing collected packages: setuptools, pip
Successfully installed pip-7.1.2 setuptools-18.2

[*] Installing (Wine) Python dependencies...

[*] Installing (Wine) Python's pywin32-220.win32-py3.4.exe...

[*] Next -> Next -> Next -> Finished! ...Overwrite if prompt (use default values)

warning [pywin32-220.win32-py3.4.exe]: 192288 extra bytes at beginning or within zipfile
(attempting to process anyway)
0009:err:winediag:SECUR32_initNTLMSP ntlm_auth was not found or is outdated. Make sure that ntlm_auth >= 3.0.25 is in your path. Usually, you can find it in the winbind package of your distribution.

[*] Installing (Wine) Python's pycrypto-2.6.1.win32-py3.4.exe...

[*] Next -> Next -> Next -> Finished! ...Overwrite if prompt (use default values)

warning [pycrypto-2.6.1.win32-py3.4.exe]: 191515 extra bytes at beginning or within zipfile
(attempting to process anyway)

[*] Installing (OS) Python's PyInstaller (via TAR)

[*] Installing (Wine) Python's PIP pefile

Collecting pip==19.1.*
Downloading https://files.pythonhosted.org/packages/5c/e0/be401c003291b56efc55aeba6a80ab790d3d4cece2778288d65323009420/pip-19.1.1-py2.py3-none-any.whl (1.4MB)
100% |################################| 1.4MB 213kB/s
Installing collected packages: pip
Found existing installation: pip 7.1.2
Uninstalling pip-7.1.2:
Successfully uninstalled pip-7.1.2
Successfully installed pip-19.1.1
You are using pip version 19.1.1, however version 21.2.4 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
DEPRECATION: Python 3.4 support has been deprecated. pip 19.1 will be the last one supporting it. Please upgrade your Python as Python 3.4 won't be maintained after March 2019 (cf PEP 429).
Collecting future
Downloading https://files.pythonhosted.org/packages/45/0b/38b06fd9b92dc2b68d58b75f900e97884c45bedd2ff83203d933cf5851c9/future-0.18.2.tar.gz (829kB)
|################################| 829kB 781kB/s eta 0:00:01
Installing collected packages: future
Running setup.py install for future ... /0034:err:winediag:SECUR32_initNTLMSP ntlm_auth was not found or is outdated. Make sure that ntlm_auth >= 3.0.25 is in your path. Usually, you can find it in the winbind package of your distribution.
done
Successfully installed future-0.18.2
DEPRECATION: Python 3.4 support has been deprecated. pip 19.1 will be the last one supporting it. Please upgrade your Python as Python 3.4 won't be maintained after March 2019 (cf PEP 429).
Collecting pefile
Downloading https://files.pythonhosted.org/packages/f9/1e/fc4fac0169d16a98577809400bbcfac8ad1900fa792184327b360ea51fc6/pefile-2021.5.13.tar.gz (66kB)
|################################| 71kB 874kB/s eta 0:00:01
ERROR: Complete output from command python setup.py egg_info:
ERROR: Traceback (most recent call last):
File "", line 1, in
File "C:\users\ferdinandoph\Temp\pip-install-2ut2m5vm\pefile\setup.py", line 86, in
long_description = "\n".join(_read_doc().split('\n')),
File "C:\users\ferdinandoph\Temp\pip-install-2ut2m5vm\pefile\setup.py", line 33, in _read_doc
tree = ast.parse(f.read())
File "C:\Python34\lib\ast.py", line 35, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
File "", line 3789
f'Export directory contains more than 10 repeated entries '
^
SyntaxError: invalid syntax
----------------------------------------
ERROR: Command "python setup.py egg_info" failed with error code 1 in C:\users\ferdinandoph\Temp\pip-install-2ut2m5vm\pefile
[ERROR] Failed to run (wine) Python pip pefile... Exit code: 1

[*] Finished (Wine + OS) Python dependencies installation

[*] Initializing (Wine) Ruby installation...

[*] Installing (Wine) Ruby & dependencies

[*] Next -> Next -> Next -> Finished! ...Overwrite if prompt (use default values)

[*] Installing (Wine) Ruby OCRA gem...

Z:\var\lib\veil\setup-dependencies>Z:\var\lib\veil\wine\drive_c\Ruby187\bin\gem install --force --local ocra-1.3.6.gem
Successfully installed ocra-1.3.6
1 gem installed
Installing ri documentation for ocra-1.3.6...
Installing RDoc documentation for ocra-1.3.6...

[*] Extracting (Wine) Ruby dependencies...

[*] Finished Ruby installation

[*] Initializing Go installation...

[*] Installing Go x86_64 (via TAR)

[*] Finished Go installation

[*] Initializing AutoIT installation...

[*] Installing (Wine) AutoIT

[*] Next -> Next -> Next -> Finished! ...Overwrite if prompt (use default values)

[*] Finished AutoIT installation

[*] Updating Veil configuration...

[*] Detected current Veil settings. Removing...

Veil Configuration:
[] OPERATING_SYSTEM = Kali
[
] TERMINAL_CLEAR = false
[] VEIL_PATH = /usr/share/veil/
[
] WINEPREFIX = /var/lib/veil/wine/
[] TEMP_PATH = /tmp/
[
] METASPLOIT_PATH = /usr/share/metasploit-framework/
[] MSFVENOM_PATH = /usr/bin/
[
] MSFVENOM_OPTIONS =
[] PYINSTALLER_PATH = /var/lib/veil/PyInstaller-3.2.1/
[
] GOLANG_PATH = /var/lib/veil/go/

Veil-Evasion Configuration:
[] PAYLOAD_SOURCE_PATH = /var/lib/veil/output/source/
[
] PAYLOAD_COMPILED_PATH = /var/lib/veil/output/compiled/
[] HANDLER_PATH = /var/lib/veil/output/handlers/
[
] HASH_LIST = /var/lib/veil/output/hashes.txt
[I] Path '/etc/veil/' Created
[I] Configuration File Written To: '/etc/veil/settings.py'

[*] Ensuring this account (ferdinandoph) owns veil output directory (/var/lib/veil/output)...

[*] Ensuring this account (ferdinandoph) has correct ownership of /var/lib/veil/wine

[*] Finished Veil configuration...

[*] Finished environment checks

[ERROR] There was issues installing the following:

Failed to run (wine) Python pip pefile... Exit code: 1

[I] If you have any errors running Veil, run: './Veil.py --setup' and select the nuke the wine folder option

[I] Done!
`

Expected behavior

The program should install with no problems

Any additional info you want to tell me

When I try to generate a file, it crashes
I installed the program/ran the setup through a non-root account (but I used sudo)

MikeRatcliffe added a commit to MikeRatcliffe/Veil that referenced this issue Sep 8, 2022
… Exit code: 1

This simple pull request fixes Veil-Framework#471 Veil-Framework#440 Veil-Framework#475 Veil-Framework#441 Veil-Framework#428 

Veil uses Python 3.4, but the version of pefile grabbed by pip 19 uses f-string interpolation, which was not introduced until Python 3.6.

This is easily fixed by restricting the pip load of pefile to version 2019.4.18, which doesn't use f-strings.

It seems like lots of people have reported the installation failure, but have been told to make this change manually.

Nobody seems to have created a pull request to fix the issue, so here you are.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant