Merge branch 'main' into Sliver_extensions

This commit is contained in:
freefirex
2022-06-13 16:25:22 -05:00
committed by GitHub
5 changed files with 216 additions and 109 deletions
+65
View File
@@ -0,0 +1,65 @@
name: Release
on:
push:
tags: ["v[0-9]+.[0-9]+.[0-9]+"]
branches: [master]
jobs:
bof-build:
name: Build and publish tagged release
if: startsWith( github.ref, 'refs/tags/v')
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: OS Packages
run: |
sudo apt-get update --fix-missing && sudo apt-get -y install \
git build-essential zlib1g zlib1g-dev wget zip unzip \
mingw-w64 binutils-mingw-w64 g++-mingw-w64 gcc-multilib jq
- name: Minisign
run: |
MINISIGN_TMP=`mktemp -d`
cd $MINISIGN_TMP
wget https://github.com/aead/minisign/releases/download/v0.2.0/minisign-linux-amd64.tar.gz
tar xvf minisign-linux-amd64.tar.gz
mv ./minisign ~/minisign
touch ~/minisign.key && chmod 600 ~/minisign.key
echo -e "${{ secrets.MINISIGN_PRIVATE_KEY }}" > ~/minisign.key
ls -l ~/
realpath ~/
- name: Check out code
uses: actions/checkout@v2
- name: Git Fetch Tags
run: git fetch --prune --unshallow --tags -f
- name: Packages Setup
run: |
mkdir packages
- name: adcs_request
run: |
chmod +x ./make_bof.sh
./make_bof.sh adcs_request
- name: chromeKey
run: |
chmod +x ./make_bof.sh
./make_bof.sh chromeKey
- name: enableuser
run: |
chmod +x ./make_bof.sh
./make_bof.sh enableuser
- name: "Publish Release"
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
files: |
./packages/*.tar.gz
./packages/*.minisig
+42
View File
@@ -0,0 +1,42 @@
#!/bin/bash
# variables
HOME=$(pwd)
BOF=$1
SRCDIR="$HOME/src/Remote/$BOF"
OUTDIR="$HOME/Remote/$BOF"
PKGS=$HOME/packages
# compile
echo "[+] Changing directory: $SRCDIR"
cd $SRCDIR
echo "[+] Compiling: $BOF"
make
# archive
echo "[+] Creating artifact:"
mkdir artifacts # $SRCDIR/artifacts/
mv $OUTDIR/*.o ./artifacts/
VERSION=$(git describe --tags --abbrev=0)
cat extension.json | jq ".version |= \"$VERSION\"" > ./artifacts/extension.json
cd artifacts # ./src/Remote/$BOF/artifacts/
echo
pwd
ls -l
echo
# package
mkdir -p $PKGS
echo "[+] Creating package:"
MANIFEST=$(cat extension.json | base64 -w 0)
COMMAND_NAME=$(cat extension.json | jq -r .command_name)
echo "[+] executing: tar -czvf $PKGS/$COMMAND_NAME.tar.gz ."
tar -czvf $PKGS/$COMMAND_NAME.tar.gz .
cd $PKGS
echo
pwd
ls -l
# sign
echo "[+] Signing package:"
bash -c "echo \"\" | /home/runner/minisign -s /home/runner/minisign.key -S -m ./$COMMAND_NAME.tar.gz -t \"$MANIFEST\" -x $COMMAND_NAME.minisig"
+60 -60
View File
@@ -1,61 +1,61 @@
{
"name": "adcs_request",
"version": "0.0.0",
"command_name": "remote-adcs-request",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "N/A",
"help": "Request an certificate from an AD certificate server",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "adcs_request.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "adcs_request.x86.o"
}
],
"arguments": [
{
"name": "CA",
"desc": "certificate authority to make request against. format: <domain>\\<CA Name>",
"type": "wstring",
"optional": false
},
{
"name": "template",
"desc": "Template to request from CA",
"type": "wstring",
"optional": true
},
{
"name": "subject",
"desc": "Subject to use in request",
"type": "wstring",
"optional": true
},
{
"name": "alt-name",
"desc": "Alternative name to request on cert",
"type": "wstring",
"optional": true
},
{
"name": "Install",
"desc": "set to something other then zero to install cert under user account",
"type": "short",
"optional": true
},
{
"name": "Machine",
"desc": "if this is set along with install cert is installed under machine account instead of user",
"type": "short",
"optional": true
}
]
}
"name": "adcs_request",
"version": "0.0.0",
"command_name": "remote-adcs-request",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "https://github.com/sliverarmory/CS-Remote-OPs-BOF",
"help": "Request an certificate from an AD certificate server",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "adcs_request.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "adcs_request.x86.o"
}
],
"arguments": [
{
"name": "CA",
"desc": "certificate authority to make request against. format: <domain>\\<CA Name>",
"type": "wstring",
"optional": false
},
{
"name": "template",
"desc": "Template to request from CA",
"type": "wstring",
"optional": true
},
{
"name": "subject",
"desc": "Subject to use in request",
"type": "wstring",
"optional": true
},
{
"name": "alt-name",
"desc": "Alternative name to request on cert",
"type": "wstring",
"optional": true
},
{
"name": "Install",
"desc": "set to something other then zero to install cert under user account",
"type": "short",
"optional": true
},
{
"name": "Machine",
"desc": "if this is set along with install cert is installed under machine account instead of user",
"type": "short",
"optional": true
}
]
}
+23 -23
View File
@@ -1,24 +1,24 @@
{
"name": "chromeKey",
"version": "0.0.0",
"command_name": "remote-chrome-key",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "N/A",
"help": "Get Decryption key usable with Chlonium (https://github.com/rxwx/chlonium)",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "chromeKey.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "chromeKey.x86.o"
}
],
"arguments": []
}
"name": "chromeKey",
"version": "0.0.0",
"command_name": "remote-chrome-key",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "https://github.com/sliverarmory/CS-Remote-OPs-BOF",
"help": "Get Decryption key usable with Chlonium (https://github.com/rxwx/chlonium)",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "chromeKey.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "chromeKey.x86.o"
}
],
"arguments": []
}
+26 -26
View File
@@ -1,37 +1,37 @@
{
"name": "enableuser",
"version": "0.0.0",
"command_name": "remote-enable-user",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "N/A",
"help": "Unlock and enable a local / remote user account",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "enableuser.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "enableuser.x86.o"
}
],
"arguments": [
{
"name": "enableuser",
"version": "0.0.0",
"command_name": "remote-enable-user",
"extension_author": "TrustedSec",
"original_author": "TrustedSec",
"repo_url": "https://github.com/sliverarmory/CS-Remote-OPs-BOF",
"help": "Unlock and enable a local / remote user account",
"depends_on": "coff-loader",
"entrypoint": "go",
"files": [
{
"os": "windows",
"arch": "amd64",
"path": "enableuser.x64.o"
},
{
"os": "windows",
"arch": "386",
"path": "enableuser.x86.o"
}
],
"arguments": [
{
"name": "ComputerName",
"desc": "Computer to enable / unlock account on. Target DC for domain accounts. Use \"\" for local computer",
"type": "wstring",
"optional": false
},
{
},
{
"name": "Username",
"desc": "Username to unlock / enable",
"type": "wstring",
"optional": false
}
]
}
}