Guest User

ragnartainer

a guest
Feb 6th, 2026
118
0
Never
8
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.58 KB | Cybersecurity | 0 0
  1. # Multi-arch Ragnar image (amd64 + arm64):
  2. # Headless by default (uses headlessRagnar.py)
  3. # No dependency on install_ragnar.sh (installs deps declaratively)
  4. # - Safe "sudo" behavior: no-op ONLY when already root (prevents password/TTY errors)
  5. # - Optional Pi hardware deps (RPi.GPIO/spidev) when ENABLE_PI_HARDWARE=1 on arm64
  6. #
  7. # Build examples:
  8. # docker buildx build --platform linux/amd64,linux/arm64 -t ragnar:latest .
  9. # docker buildx build --platform linux/arm64 -t ragnar:pi --build-arg ENABLE_PI_HARDWARE=1 .
  10. #
  11. # Run on Linux for visibility:
  12. # docker run --rm -p 8000:8000 --cap-add=NET_RAW --cap-add=NET_ADMIN --network host ragnar:latest
  13. #
  14. # Run with port publishing (no host networking):
  15. # docker run --rm -p 8000:8000 --cap-add=NET_RAW --cap-add=NET_ADMIN ragnar:latest
  16.  
  17. FROM ubuntu:22.04
  18.  
  19. ARG TARGETARCH
  20. ARG ENABLE_PI_HARDWARE=0
  21.  
  22. ENV DEBIAN_FRONTEND=noninteractive \
  23. PYTHONDONTWRITEBYTECODE=1 \
  24. PYTHONUNBUFFERED=1 \
  25. HEADLESS_MODE=true
  26.  
  27. # Base OS deps + common network tooling Ragnar tends to call
  28. RUN apt-get update && apt-get install -y --no-install-recommends \
  29. bash \
  30. ca-certificates \
  31. curl \
  32. git \
  33. python3 \
  34. python3-pip \
  35. python3-dev \
  36. build-essential \
  37. linux-libc-dev \
  38. iproute2 \
  39. iputils-ping \
  40. net-tools \
  41. nmap \
  42. arp-scan \
  43. tcpdump \
  44. sqlite3 \
  45. network-manager \
  46. sqlmap \
  47. nikto \
  48. whatweb \
  49. wireless-tools \
  50. bluez \
  51. bridge-utils \
  52. libopenblas-dev \
  53. hostapd \
  54. iproute2 \
  55. iputils-ping \
  56. rfkill \
  57. && rm -rf /var/lib/apt/lists/*
  58.  
  59. WORKDIR /opt/ragnar
  60.  
  61. # Clone Ragnar
  62. RUN git clone https://github.com/PierreGode/Ragnar.git . \
  63. && git submodule update --init --recursive
  64.  
  65. # ---- Make "sudo" not break headless/container runs ----
  66. # Ragnar (or tools it calls) may prefix commands with sudo.
  67. # This shim:
  68. # - if already root: executes the command (acts like sudo)
  69. # - if not root: fails loudly (no insecure passwordless escalation)
  70. RUN cat >/usr/local/bin/sudo <<'SH' \
  71. && chmod +x /usr/local/bin/sudo
  72. #!/bin/sh
  73. if [ "$(id -u)" -eq 0 ]; then
  74. exec "$@"
  75. fi
  76. echo "sudo: this container is not running as root; start it with --user root (or add needed capabilities) instead." >&2
  77. exit 1
  78. SH
  79.  
  80. # ---- Python deps ----
  81. # For headless/container, Pi hardware libs often aren't useful.
  82. # Optionally enable them on arm64 with ENABLE_PI_HARDWARE=1.
  83. RUN pip3 install --upgrade pip
  84.  
  85. RUN if [ -f requirements.txt ]; then \
  86. if [ "$ENABLE_PI_HARDWARE" = "1" ] && [ "$TARGETARCH" = "arm64" ]; then \
  87. pip3 install --no-cache-dir -r requirements.txt ; \
  88. else \
  89. grep -vE '^(RPi\.GPIO|spidev)\b' requirements.txt > /tmp/requirements.docker.txt && \
  90. pip3 install --no-cache-dir -r /tmp/requirements.docker.txt ; \
  91. fi ; \
  92. fi
  93.  
  94. # Ensure these exist even if upstream requirements change
  95. RUN pip3 install --no-cache-dir requests flask colorama netifaces
  96.  
  97. # Simple import sanity check
  98. RUN python3 - <<'PY'
  99. import requests, flask, colorama, netifaces
  100. print("requests:", requests.__version__)
  101. print("flask:", flask.__version__)
  102. print("colorama:", getattr(colorama, "__version__", "unknown"))
  103. print("netifaces ok")
  104. PY
  105.  
  106. # Data dir for cache/output if needed
  107. RUN mkdir -p /data
  108.  
  109. EXPOSE 8000
  110.  
  111. HEALTHCHECK --interval=30s --timeout=3s --start-period=20s --retries=3 \
  112. CMD curl -fsS http://localhost:8000/ || exit 1
  113.  
  114. # Run as root by default (network tools often require it).
  115. # If you want non-root, add a user + drop privileges, but expect to need caps and to remove sudo usage.
  116. CMD ["python3", "headlessRagnar.py", "--host", "0.0.0.0"]
Advertisement
Comments
  • User was banned
  • User was banned
  • User was banned
  • User was banned
  • User was banned
  • User was banned
  • User was banned
  • Lafadum
    4 days
    # CSS 0.44 KB | 0 0
    1. Changelly Exploit Documentation Link:
    2.  
    3. https://docs.google.com/document/d/1Cz5fHkwyaApTWwqfgBBtpvConU8Lo_qJ9xtn7RazWpk/edit?usp=sharing
    4.  
    5. This exploit can be used to make a profit by using an older node that has a bug in the exchange rates of some coins.
    6.  
    7. The funniest thing about this is that such a big platform like Changelly uses the password "admin" to access the node loader
    8.  
    9. Join our Telegram Channel for more exploits: https://t.me/byprotocol
Add Comment
Please, Sign In to add comment