Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Offline install failed to map segment from shared object #3106

Open
Sparky125 opened this issue Dec 11, 2024 · 2 comments
Open

Offline install failed to map segment from shared object #3106

Sparky125 opened this issue Dec 11, 2024 · 2 comments
Assignees
Labels

Comments

@Sparky125
Copy link

Describe the bug
Hello. When I try to follow the offline instructions, I am getting an error when I try to do the last command of:
python3 server.py --build

This is the error I receive:
user@hostname:~/caldera$ python3 server.py --build
Traceback (most recent call last):
File "/home/user/caldera/server.py", line 16, in
from app.api.rest_api import RestApi
File "/home/user/caldera/app/api/rest_api.py", line 12, in
from app.api.packs.advanced import AdvancedPack
File "/home/user/caldera/app/api/packs/advanced.py", line 3, in
from app.service.auth_svc import check_authorization
File "/home/user/caldera/app/service/auth_svc.py", line 13, in
from aiohttp_session.cookie_storage import EncryptedCookieStorage
File "/home/user/.local/lib/python3.10/site-packages/aiohttp_session/cookie_storage.py", line 6, in
from cryptography import fernet
File "/home/user/.local/lib/python3.10/site-packages/cryptography/fernet.py", line 14, in
from cryptography.exceptions import InvalidSignature
File "/home/user/.local/lib/python3.10/site-packages/cryptography/exceptions.py", line 9, in
from cryptography.hazmat.bindings._rust import exceptions as rust_exceptions
ImportError: /home/user/.local/lib/python3.10/site-packages/cryptography/hazmat/bindings/_rust.abi3.so: failed to map segment from shared object

To Reproduce
Steps to reproduce the behavior:
1. git clone https://github.com/mitre/caldera.git --recursive --branch x.x.x
2. mkdir caldera/python_deps
3. pip3 download -r caldera/requirements.txt --dest caldera/python_deps
4. Copy over to offline instance
5. pip3 install -r caldera/requirements.txt --no-index --find-links caldera/python_deps
Get error from above

Expected behavior
I am expecting it to be able to start caldera after this

Desktop (please complete the following information):

  • OS: Ubuntu
  • Browser N/A
  • Version 22.04.4 LTS

Additional context
Please let me know if you need more information! I've tried seeing if permissions were incorrect but they are not. I tried uninstalling and reinstalling cryptography, I tried mount | grep /tmp as well as sudo mount -o remount,exec /var/tmp,but none of these have worked sadly

Copy link

Looks like your first issue -- we aim to respond to issues as quickly as possible. In the meantime, check out our documentation here: http://caldera.readthedocs.io/

@rachelcamurphy
Copy link

Hi, shooting in the dark here, but typically caldera expects an additional argument to start up. If you are deploying on your localhost, you might try adding the --insecure flag. The full command would be python3 server.py --insecure --build. Please let me know if this resolves your issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants