PokemonGo-Bot icon indicating copy to clipboard operation
PokemonGo-Bot copied to clipboard

invalid ELF header for ./encrypt.so

Open MaxxLi opened this issue 10 years ago • 7 comments

Currently running Docker in MacOS, did the full installation and config setups. After getting encrypt no file found, I followed the steps to remake the libencrypt.so and renamed it to encrypt.so and put into PokemonGo-Bot/ directory...However running the new build, it returns:

File "pokecli.py", line 493, in main() File "pokecli.py", line 127, in main report_summary(bot) File "pokecli.py", line 136, in report_summary metrics.capture_stats() File "/usr/src/app/pokemongo_bot/metrics.py", line 76, in capture_stats response_dict = request.call() File "/usr/src/app/pokemongo_bot/api_wrapper.py", line 106, in call result = self._call() File "/usr/src/app/pokemongo_bot/api_wrapper.py", line 63, in _call return PGoApiRequest.call(self) File "/usr/src/app/src/pgoapi/pgoapi/pgoapi.py", line 210, in call request.activate_signature(lib_path) File "/usr/src/app/src/pgoapi/pgoapi/rpc_api.py", line 85, in activate_signature self._signature_lib = ctypes.cdll.LoadLibrary(lib_path) File "/usr/local/lib/python2.7/ctypes/init.py", line 440, in LoadLibrary return self._dlltype(name) File "/usr/local/lib/python2.7/ctypes/init.py", line 362, in init self._handle = _dlopen(self._name, mode) OSError: ./encrypt.so: invalid ELF header

Please help :S

MaxxLi avatar Aug 07 '16 08:08 MaxxLi

Had same problem with linux64 bit but after recompiling encrypt.so it worked. maybe you still have the wrong encrypt.so in your path that the bot is searching

AcorpBG avatar Aug 07 '16 08:08 AcorpBG

How to make an encrypt.so on windows? I met the same problem

bddr avatar Aug 07 '16 08:08 bddr

Run this command on the system you gonna run the script. wget http://pgoapi.com/pgoencrypt.tar.gz && tar -xf pgoencrypt.tar.gz && cd pgoencrypt/src/ && make

After that copy the libencrypt.so to your bot directory and rename it to encrypt.so. This file is different for each system so recreate when ever you switch systems.

nmolenaar avatar Aug 07 '16 09:08 nmolenaar

Thanks senpai you are great!!!

rhythem avatar Aug 07 '16 10:08 rhythem

https://github.com/PokemonGoF/PokemonGo-Bot/issues/2780

bruvv avatar Aug 07 '16 13:08 bruvv

Expected Behavior

Successful Run

Actual Behavior

OSError: encrypt.so: invalid ELF header

Steps to Reproduce

docker run --name=bot1-pokego --rm -it -v $(pwd)/configs/config-account1.json:/usr/src/app/configs/config.json pokemongo-bot

Other Information

OS: OSX Git Commit: 81e16731200ff50c4cfe8a0ad049eac7f5441368 Python Version: 2.7.12

i follow above method but still not working. ./run.sh is working fine. I also read about #2808 #2780

ytyeoh avatar Aug 21 '16 02:08 ytyeoh

I'm having same problem as @ytyeoh and I see that, in docker Found encrypt.so! Platform: linux2 encrypt.so directory: /usr/src/app

but in my system: Found encrypt.so! Platform: darwin encrypt.so directory

kofainhi avatar Aug 21 '16 02:08 kofainhi