Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
MEhrn00 committed Feb 17, 2024
1 parent 2f82b60 commit dfc22b0
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 4 deletions.
16 changes: 14 additions & 2 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,10 @@ ARG userUid=1000
ARG userGid=1000
ARG upgradePackages=false
ARG goversion=1.22.0
ARG golangcilintversion=v1.56.2
ARG golangcilintversion=1.56.2
ARG shell=bash
ARG extraPackages
ARG protocversion=25.3

# Update apt cache
RUN apt-get update -y
Expand All @@ -29,6 +30,7 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get install -y \
mingw-w64 \
pkg-config \
llvm \
unzip \
libssl-dev

# Install Golang
Expand All @@ -42,7 +44,7 @@ RUN rm -f go${goversion}.linux-amd64.tar.gz
# Install golangci-lint
USER ${username}
RUN mkdir -p /home/${username}/go/bin
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b /home/${username}/go/bin ${golangcilintversion}
RUN curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b /home/${username}/go/bin v${golangcilintversion}

# Install Rust
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs -o rustup.sh \
Expand All @@ -62,6 +64,16 @@ RUN $HOME/.cargo/bin/rustup component add rustfmt clippy

USER 0

# Install protoc
RUN mkdir -p /tmp/protoc
WORKDIR /tmp/protoc
RUN curl -L https://github.com/protocolbuffers/protobuf/releases/download/v${protocversion}/protoc-${protocversion}-linux-x86_64.zip -o protoc.zip
RUN unzip protoc.zip
RUN mv bin/protoc /usr/local/bin
RUN chmod 755 /usr/local/bin/protoc
WORKDIR /tmp
RUN rm -rf /tmp/protoc

# Ensure zsh is installed if the shell is zsh
RUN if [ "${shell}" = "zsh" ]; then apt-get install -y zsh; fi

Expand Down
3 changes: 1 addition & 2 deletions Payload_Type/thanatos/agent/thanatos/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,8 @@
use agent::Agent;
use config::ConfigVars;

mod guardrails;

mod agent;
mod guardrails;
mod logging;
mod native;
mod proto;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

2 changes: 2 additions & 0 deletions Payload_Type/thanatos/agent/thanatos/src/native/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,5 @@ pub mod linux;

#[cfg(target_os = "windows")]
pub mod windows;

mod checkininfo;
4 changes: 4 additions & 0 deletions thanatos.code-workspace
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
"name": "Agent code",
"path": "Payload_Type/thanatos/agent"
},
{
"name": "Protobuf",
"path": "Payload_Type/thanatos/mythic/protos"
},
{
"name": "Base Dockerfile",
"path": "Payload_Type/thanatos/.docker"
Expand Down

0 comments on commit dfc22b0

Please sign in to comment.