-
Notifications
You must be signed in to change notification settings - Fork 190
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #126 from chrismaddalena/master
Ghostwriter v2.0
- Loading branch information
Showing
168 changed files
with
8,433 additions
and
3,586 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,38 +9,3 @@ DJANGO_ACCOUNT_EMAIL_VERIFICATION=none | |
# ------------------------------------------------------------------------------ | ||
QCLUSTER_NAME=soar | ||
# QCLUSTER_CONNECTION= | ||
|
||
# Virustotal | ||
# ------------------------------------------------------------------------------ | ||
VIRUSTOTAL_API_KEY=None | ||
|
||
# Slack | ||
# ------------------------------------------------------------------------------ | ||
SLACK_ENABLE=True | ||
SLACK_EMOJI=:ghost: | ||
SLACK_CHANNEL=#ghostwriter | ||
SLACK_ALERT_TARGET=<!here> | ||
SLACK_USERNAME=ghostwriter | ||
SLACK_URL=https://hooks.slack.com/services/<your_webhook_url> | ||
|
||
# Company Info | ||
# ------------------------------------------------------------------------------ | ||
COMPANY_NAME=Ghostwriter | ||
COMPANY_TWITTER=@ghostwriter | ||
[email protected] | ||
|
||
# Namecheap | ||
# ------------------------------------------------------------------------------ | ||
NAMECHEAP_ENABLE=False | ||
NAMECHEAP_API_KEY= | ||
NAMECHEAP_USERNAME= | ||
NAMECHEAP_API_USERNAME= | ||
CLIENT_IP= | ||
NAMECHEAP_PAGE_SIZE=100 | ||
|
||
# Cloud Services | ||
# ------------------------------------------------------------------------------ | ||
ENABLE_CLOUD_MONITOR=False | ||
AWS_KEY= | ||
AWS_SECRET= | ||
DO_API_KEY= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,38 +38,3 @@ REDIS_URL=redis://redis:6379/0 | |
# ------------------------------------------------------------------------------ | ||
QCLUSTER_NAME=soar | ||
# QCLUSTER_CONNECTION= | ||
|
||
# Virustotal | ||
# ------------------------------------------------------------------------------ | ||
VIRUSTOTAL_API_KEY=None | ||
|
||
# Slack | ||
# ------------------------------------------------------------------------------ | ||
SLACK_ENABLE=True | ||
SLACK_EMOJI=:ghost: | ||
SLACK_CHANNEL=#ghostwriter | ||
SLACK_ALERT_TARGET=<!here> | ||
SLACK_USERNAME=ghostwriter | ||
SLACK_URL=https://hooks.slack.com/services/<your_webhook_url> | ||
|
||
# Company Info | ||
# ------------------------------------------------------------------------------ | ||
COMPANY_NAME=Ghostwriter | ||
COMPANY_TWITTER=@ghostwriter | ||
[email protected] | ||
|
||
# Namecheap | ||
# ------------------------------------------------------------------------------ | ||
NAMECHEAP_ENABLE=False | ||
NAMECHEAP_API_KEY= | ||
NAMECHEAP_USERNAME= | ||
NAMECHEAP_API_USERNAME= | ||
CLIENT_IP= | ||
NAMECHEAP_PAGE_SIZE=100 | ||
|
||
# Cloud Services | ||
# ------------------------------------------------------------------------------ | ||
ENABLE_CLOUD_MONITOR=False | ||
AWS_KEY= | ||
AWS_SECRET= | ||
DO_API_KEY= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import requests | ||
import json | ||
|
||
# Replace with a URL, API, and ID key for your instance | ||
url = "http://127.0.0.1:8000/oplog/api/entries/" | ||
api_key = "API_KEY" | ||
oplog_id = 1 | ||
|
||
headers = { | ||
"user-agent": "Python", | ||
"Content-Type": "application/json", | ||
"Authorization": f"Api-Key {api_key}", | ||
} | ||
|
||
data = { | ||
"start_date": None, | ||
"end_date": None, | ||
"source_ip": "WIN10VM (10.20.10.10)", | ||
"dest_ip": "127.0.0.1", | ||
"tool": "Beacon", | ||
"user_context": "ADMIN", | ||
"command": "execute_assembly /tmp/Seatbelt.exe logonevents", | ||
"description": "", | ||
"output": "", | ||
"comments": "", | ||
"operator_name": "Benny", | ||
"oplog_id": "1", | ||
} | ||
|
||
print("[+] Sending request to Ghostwriter...") | ||
|
||
resp = requests.post(url, headers=headers, data=json.dumps(data)) | ||
|
||
if resp.status_code == 201: | ||
print(f"[+] Received code 201, so log was created: {resp.text}") | ||
else: | ||
print( | ||
f"[!] Received status code {resp.status_code}, so something went wrong: {resp.text}" | ||
) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,54 @@ | ||
# Ghostwriter | ||
|
||
[![Python Version](https://img.shields.io/badge/Python-3.7-brightgreen.svg)](.) [![License](https://img.shields.io/badge/License-BSD3-darkred.svg)](.) [![Black Hat Arsenal 2019](https://img.shields.io/badge/2019-Black%20Hat%20Arsenal-lightgrey.svg)](.) | ||
[![Python Version](https://img.shields.io/badge/Python-3.8-brightgreen.svg)](.) [![License](https://img.shields.io/badge/License-BSD3-darkred.svg)](.) [![Black Hat Arsenal 2019](https://img.shields.io/badge/2019-Black%20Hat%20Arsenal-lightgrey.svg)](https://www.blackhat.com/us-19/arsenal/schedule/index.html#ghostwriter-15475) | ||
|
||
![ghostwriter](https://github.com/GhostManager/Ghostwriter/raw/master/DOCS/images/logo.png) | ||
![GitHub release (latest by date)](https://img.shields.io/github/v/release/GhostManager/Ghostwriter) | ||
![GitHub Release Date](https://img.shields.io/github/release-date/ghostmanager/ghostwriter) | ||
|
||
Ghostwriter is a Django project written in Python 3.7 and is designed to be used by a team of operators. The platform is made up of several Django apps that own different roles but work together. See the Wiki for more information. | ||
![ghostwriter](DOCS/images/logo.png) | ||
|
||
Ghostwriter is a Django project written in Python 3.8 and is designed to be used by a team of operators. The platform is made up of several Django apps that own different roles but work together. | ||
|
||
## Details | ||
|
||
Check-out the introductory blogpost: [Introducing Ghostwriter](https://posts.specterops.io/introducing-ghostwriter-part-1-61e7bd014aff) | ||
|
||
This blogpost discusses the design and intent behind Ghostwriter: [Introducing Ghostwriter: Part 2](https://posts.specterops.io/introducing-ghostwriter-part-2-f2d8368a1ed6) | ||
|
||
## Documentation | ||
|
||
The Ghostwriter Wiki contains everything you need to know to use or customize Ghostwriter: | ||
|
||
[Ghostwriter Wiki](https://ghostwriter.wiki/) | ||
|
||
The wiki covers everything from installation and setup information for first time users to database schemas, the project's code style guide, and how to expand or customie parts of the project to fit your needs. | ||
|
||
## Getting Help | ||
|
||
[![Slack Status](https://img.shields.io/badge/Slack-%23ghostwriter-blueviolet)](https://bloodhoundgang.herokuapp.com) | ||
|
||
The quickest way to get help is Slack. The BloodHound Slack Team has a #ghostwriter channel for discussing this project and requesting assistance. There is also a #reporting channel for discussing various topics related to writing and managing reports and findings. | ||
|
||
You can submit an issue. If you do, please use the issue template and provide as much information as possible. | ||
|
||
Before submitting an issue, review the [Ghostwriter Wiki](https://ghostwriter.wiki/). Many of the common issues new users encounter stem from missing a step (like loading the seed data to prep the database) or an issue with Docker on their host system. | ||
|
||
## Contributing to the Project | ||
|
||
Please open issues or submit pull requests! The project team welcomes feedback, new ideas, and external contributions. Before submitting a PR, please check open and closed issues for any previous related discussion. Also, the submitted code must follow the [Code Style Guide](https://ghostwriter.wiki/coding-style-guide/style-guide) to be accepted. | ||
|
||
We only ask that you limit PR submissions to those that fix a bug, enhance an existing feature, or add something new. | ||
|
||
## Contributions | ||
|
||
The following people have contributed much to this project: | ||
|
||
* [@covertgeek](https://github.com/covertgeek) | ||
* [@hotnops](https://github.com/hotnops) | ||
* [@andrewchiles](https://github.com/andrewchiles) | ||
|
||
These folks kindly submitted feedback and PRs to fix bugs and enhance existing features. Thank you! | ||
|
||
* [@fastlorenzo](https://github.com/fastlorenzo) | ||
* [@mattreduce](https://github.com/mattreduce) | ||
* [@dbuentello](https://github.com/dbuentello) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
"""This contains all of the WebSocket routes used by the Ghostwriter application.""" | ||
|
||
# Django & Other 3rd Party Libraries | ||
from django.urls import path | ||
from channels.routing import ProtocolTypeRouter, URLRouter | ||
from channels.auth import AuthMiddlewareStack | ||
|
||
# Ghostwriter Libraries | ||
from ghostwriter.oplog.consumers import OplogEntryConsumer | ||
|
||
application = ProtocolTypeRouter( | ||
{ | ||
"websocket": AuthMiddlewareStack( | ||
URLRouter([path("ws/oplog/<int:pk>/entries", OplogEntryConsumer)]) | ||
) | ||
} | ||
) |
Oops, something went wrong.