Skip to content
Permalink
Browse files

First commit

  • Loading branch information...
Christopher Maddalena
Christopher Maddalena committed Jul 30, 2019
0 parents commit ea9c59c3eda7304b1a18cc6a14b731a729630c03
Showing with 52,456 additions and 0 deletions.
  1. +5 −0 .coveragerc
  2. +4 −0 .dockerignore
  3. +33 −0 .editorconfig
  4. +30 −0 .envs_template/.local/.django
  5. +7 −0 .envs_template/.local/.postgres
  6. +61 −0 .envs_template/.production/.django
  7. +7 −0 .envs_template/.production/.postgres
  8. +1 −0 .gitattributes
  9. +273 −0 .gitignore
  10. +14 −0 .pylintrc
  11. +3 −0 .vscode/settings.json
  12. +1 −0 CONTRIBUTORS.txt
  13. +153 −0 DOCS/Makefile
  14. BIN DOCS/UML/all_models.png
  15. BIN DOCS/UML/ghostwriter_models.png
  16. BIN DOCS/UML/home_models.png
  17. BIN DOCS/UML/rolodex_models.png
  18. BIN DOCS/UML/shepherd_models.png
  19. +1 −0 DOCS/__init__.py
  20. +255 −0 DOCS/conf.py
  21. BIN DOCS/images/logo.png
  22. +20 −0 DOCS/index.rst
  23. +190 −0 DOCS/make.bat
  24. BIN DOCS/screenshots/scheduled-tasks-domain-release.png
  25. +29 −0 LICENSE
  26. +8 −0 README.md
  27. +44 −0 compose/local/django/Dockerfile
  28. +9 −0 compose/local/django/seed_data
  29. +14 −0 compose/local/django/start
  30. +54 −0 compose/production/django/Dockerfile
  31. +42 −0 compose/production/django/entrypoint
  32. +7 −0 compose/production/django/queue/start
  33. +9 −0 compose/production/django/seed_data
  34. +15 −0 compose/production/django/start
  35. +4 −0 compose/production/nginx/Dockerfile
  36. +125 −0 compose/production/nginx/nginx.conf
  37. +6 −0 compose/production/postgres/Dockerfile
  38. +5 −0 compose/production/postgres/maintenance/_sourced/constants.sh
  39. +12 −0 compose/production/postgres/maintenance/_sourced/countdown.sh
  40. +41 −0 compose/production/postgres/maintenance/_sourced/messages.sh
  41. +16 −0 compose/production/postgres/maintenance/_sourced/yes_no.sh
  42. +38 −0 compose/production/postgres/maintenance/backup
  43. +22 −0 compose/production/postgres/maintenance/backups
  44. +55 −0 compose/production/postgres/maintenance/restore
  45. 0 config/__init__.py
  46. 0 config/settings/__init__.py
  47. +321 −0 config/settings/base.py
  48. +62 −0 config/settings/local.py
  49. +163 −0 config/settings/production.py
  50. +53 −0 config/settings/test.py
  51. +48 −0 config/urls.py
  52. +39 −0 config/wsgi.py
  53. +7 −0 ghostwriter/__init__.py
  54. +20 −0 ghostwriter/conftest.py
  55. +5 −0 ghostwriter/contrib/__init__.py
  56. +5 −0 ghostwriter/contrib/sites/__init__.py
  57. +42 −0 ghostwriter/contrib/sites/migrations/0001_initial.py
  58. +20 −0 ghostwriter/contrib/sites/migrations/0002_alter_domain_unique.py
  59. +34 −0 ghostwriter/contrib/sites/migrations/0003_set_site_domain_and_name.py
  60. +5 −0 ghostwriter/contrib/sites/migrations/__init__.py
  61. 0 ghostwriter/home/__init__.py
  62. +12 −0 ghostwriter/home/admin.py
  63. +11 −0 ghostwriter/home/apps.py
  64. +42 −0 ghostwriter/home/forms.py
  65. +27 −0 ghostwriter/home/migrations/0001_initial.py
  66. +23 −0 ghostwriter/home/migrations/0002_userprofile_user.py
  67. +19 −0 ghostwriter/home/migrations/0003_auto_20190729_2213.py
  68. 0 ghostwriter/home/migrations/__init__.py
  69. +61 −0 ghostwriter/home/models.py
  70. +17 −0 ghostwriter/home/signals.py
  71. +85 −0 ghostwriter/home/templates/home/management.html
  72. +57 −0 ghostwriter/home/templates/home/profile.html
  73. +36 −0 ghostwriter/home/templates/home/upload_avatar.html
  74. +3 −0 ghostwriter/home/tests.py
  75. +19 −0 ghostwriter/home/urls.py
  76. +131 −0 ghostwriter/home/views.py
  77. 0 ghostwriter/modules/__init__.py
  78. +69 −0 ghostwriter/modules/codenames.py
  79. +54 −0 ghostwriter/modules/dns.py
  80. +1,416 −0 ghostwriter/modules/reportwriter.py
  81. +609 −0 ghostwriter/modules/review.py
  82. 0 ghostwriter/reporting/__init__.py
  83. +62 −0 ghostwriter/reporting/admin.py
  84. +11 −0 ghostwriter/reporting/apps.py
  85. +52 −0 ghostwriter/reporting/filters.py
  86. +77 −0 ghostwriter/reporting/fixtures/initial.json
  87. +121 −0 ghostwriter/reporting/forms.py
  88. +141 −0 ghostwriter/reporting/migrations/0001_initial.py
  89. 0 ghostwriter/reporting/migrations/__init__.py
  90. +421 −0 ghostwriter/reporting/models.py
  91. +98 −0 ghostwriter/reporting/tasks.py
  92. +35 −0 ghostwriter/reporting/templates/reporting/archives.html
  93. +57 −0 ghostwriter/reporting/templates/reporting/evidence_detail.html
  94. +80 −0 ghostwriter/reporting/templates/reporting/evidence_form.html
  95. +115 −0 ghostwriter/reporting/templates/reporting/finding_detail.html
  96. +120 −0 ghostwriter/reporting/templates/reporting/finding_form.html
  97. +124 −0 ghostwriter/reporting/templates/reporting/finding_list.html
  98. +66 −0 ghostwriter/reporting/templates/reporting/findings_import.html
  99. +152 −0 ghostwriter/reporting/templates/reporting/local_edit.html
  100. +14 −0 ghostwriter/reporting/templates/reporting/local_remove.html
  101. +180 −0 ghostwriter/reporting/templates/reporting/report_detail.html
  102. +21 −0 ghostwriter/reporting/templates/reporting/report_form.html
  103. +80 −0 ghostwriter/reporting/templates/reporting/report_list.html
  104. BIN ghostwriter/reporting/templates/reports/template.docx
  105. BIN ghostwriter/reporting/templates/reports/template.pptx
  106. +3 −0 ghostwriter/reporting/tests.py
  107. +141 −0 ghostwriter/reporting/urls.py
  108. +1,019 −0 ghostwriter/reporting/views.py
  109. 0 ghostwriter/rolodex/__init__.py
  110. +77 −0 ghostwriter/rolodex/admin.py
  111. +11 −0 ghostwriter/rolodex/apps.py
  112. +51 −0 ghostwriter/rolodex/fixtures/initial.json
  113. +223 −0 ghostwriter/rolodex/forms.py
  114. +144 −0 ghostwriter/rolodex/migrations/0001_initial.py
  115. 0 ghostwriter/rolodex/migrations/__init__.py
  116. +351 −0 ghostwriter/rolodex/models.py
  117. +85 −0 ghostwriter/rolodex/templates/rolodex/assignment_form.html
  118. +191 −0 ghostwriter/rolodex/templates/rolodex/client_detail.html
  119. +53 −0 ghostwriter/rolodex/templates/rolodex/client_form.html
  120. +44 −0 ghostwriter/rolodex/templates/rolodex/client_list.html
  121. +65 −0 ghostwriter/rolodex/templates/rolodex/contact_form.html
  122. +401 −0 ghostwriter/rolodex/templates/rolodex/project_detail.html
  123. +76 −0 ghostwriter/rolodex/templates/rolodex/project_form.html
  124. +46 −0 ghostwriter/rolodex/templates/rolodex/project_list.html
  125. +3 −0 ghostwriter/rolodex/tests.py
  126. +96 −0 ghostwriter/rolodex/urls.py
  127. +674 −0 ghostwriter/rolodex/views.py
  128. 0 ghostwriter/shepherd/__init__.py
  129. +96 −0 ghostwriter/shepherd/admin.py
  130. +13 −0 ghostwriter/shepherd/apps.py
  131. +34 −0 ghostwriter/shepherd/filters.py
  132. +184 −0 ghostwriter/shepherd/fixtures/initial.json
  133. +361 −0 ghostwriter/shepherd/forms.py
  134. +269 −0 ghostwriter/shepherd/migrations/0001_initial.py
  135. +18 −0 ghostwriter/shepherd/migrations/0002_auto_20190726_1841.py
  136. 0 ghostwriter/shepherd/migrations/__init__.py
  137. +728 −0 ghostwriter/shepherd/models.py
  138. +390 −0 ghostwriter/shepherd/tasks.py
  139. +23 −0 ghostwriter/shepherd/templates/shepherd/burn.html
  140. +101 −0 ghostwriter/shepherd/templates/shepherd/checkout.html
  141. +143 −0 ghostwriter/shepherd/templates/shepherd/checkouts_for_user.html
  142. +59 −0 ghostwriter/shepherd/templates/shepherd/connect_form.html
  143. +275 −0 ghostwriter/shepherd/templates/shepherd/domain_detail.html
  144. +123 −0 ghostwriter/shepherd/templates/shepherd/domain_form.html
  145. +75 −0 ghostwriter/shepherd/templates/shepherd/domain_import.html
  146. +146 −0 ghostwriter/shepherd/templates/shepherd/domain_list.html
  147. +72 −0 ghostwriter/shepherd/templates/shepherd/graveyard.html
  148. +4 −0 ghostwriter/shepherd/templates/shepherd/project_dropdown_list.html
  149. +105 −0 ghostwriter/shepherd/templates/shepherd/server_checkout.html
  150. +100 −0 ghostwriter/shepherd/templates/shepherd/server_detail.html
  151. +69 −0 ghostwriter/shepherd/templates/shepherd/server_form.html
  152. +65 −0 ghostwriter/shepherd/templates/shepherd/server_import.html
  153. +95 −0 ghostwriter/shepherd/templates/shepherd/server_list.html
  154. +81 −0 ghostwriter/shepherd/templates/shepherd/update.html
  155. +48 −0 ghostwriter/shepherd/templates/shepherd/vps_form.html
  156. +3 −0 ghostwriter/shepherd/tests.py
  157. +121 −0 ghostwriter/shepherd/urls.py
  158. +1,398 −0 ghostwriter/shepherd/views.py
  159. +923 −0 ghostwriter/static/css/styles.css
  160. +2 −0 ghostwriter/static/files/template.csv
  161. 0 ghostwriter/static/fonts/.gitkeep
  162. BIN ghostwriter/static/images/default_avatar.png
  163. BIN ghostwriter/static/images/domain.png
  164. BIN ghostwriter/static/images/favicons/favicon.ico
  165. BIN ghostwriter/static/images/font_ghost.png
  166. BIN ghostwriter/static/images/ghost-alert.png
  167. BIN ghostwriter/static/images/ghost.png
  168. BIN ghostwriter/static/images/logo.png
  169. BIN ghostwriter/static/images/outline.png
  170. BIN ghostwriter/static/images/tombstone.png
  171. +333 −0 ghostwriter/static/jquery/AUTHORS.txt
  172. +43 −0 ghostwriter/static/jquery/LICENSE.txt
  173. +11,008 −0 ghostwriter/static/jquery/external/jquery/jquery.js
  174. BIN ghostwriter/static/jquery/images/ui-icons_444444_256x240.png
  175. BIN ghostwriter/static/jquery/images/ui-icons_555555_256x240.png
  176. BIN ghostwriter/static/jquery/images/ui-icons_777620_256x240.png
  177. BIN ghostwriter/static/jquery/images/ui-icons_777777_256x240.png
  178. BIN ghostwriter/static/jquery/images/ui-icons_cc0000_256x240.png
  179. BIN ghostwriter/static/jquery/images/ui-icons_ffffff_256x240.png
  180. +559 −0 ghostwriter/static/jquery/index.html
  181. +1,312 −0 ghostwriter/static/jquery/jquery-ui.css
  182. +18,706 −0 ghostwriter/static/jquery/jquery-ui.js
  183. +7 −0 ghostwriter/static/jquery/jquery-ui.min.css
  184. +13 −0 ghostwriter/static/jquery/jquery-ui.min.js
  185. +886 −0 ghostwriter/static/jquery/jquery-ui.structure.css
  186. +5 −0 ghostwriter/static/jquery/jquery-ui.structure.min.css
  187. +443 −0 ghostwriter/static/jquery/jquery-ui.theme.css
  188. +5 −0 ghostwriter/static/jquery/jquery-ui.theme.min.css
  189. +74 −0 ghostwriter/static/jquery/package.json
  190. +214 −0 ghostwriter/static/jquery/theme.dropbox.css
  191. +1 −0 ghostwriter/static/js/project.js
  192. 0 ghostwriter/static/sass/custom_bootstrap_vars.scss
  193. +40 −0 ghostwriter/static/sass/project.scss
  194. +2 −0 ghostwriter/static/scripts/list.min.js
  195. +9 −0 ghostwriter/templates/403.html
  196. +9 −0 ghostwriter/templates/404.html
  197. +13 −0 ghostwriter/templates/500.html
  198. +11 −0 ghostwriter/templates/account/account_inactive.html
  199. +10 −0 ghostwriter/templates/account/base.html
  200. +75 −0 ghostwriter/templates/account/email.html
  201. +29 −0 ghostwriter/templates/account/email_confirm.html
  202. +51 −0 ghostwriter/templates/account/login.html
  203. +19 −0 ghostwriter/templates/account/logout.html
  204. +16 −0 ghostwriter/templates/account/password_change.html
  205. +22 −0 ghostwriter/templates/account/password_reset.html
  206. +16 −0 ghostwriter/templates/account/password_reset_done.html
  207. +24 −0 ghostwriter/templates/account/password_reset_from_key.html
  208. +9 −0 ghostwriter/templates/account/password_reset_from_key_done.html
  209. +14 −0 ghostwriter/templates/account/password_set.html
  210. +19 −0 ghostwriter/templates/account/signup.html
  211. +11 −0 ghostwriter/templates/account/signup_closed.html
  212. +13 −0 ghostwriter/templates/account/verification_sent.html
  213. +24 −0 ghostwriter/templates/account/verified_email_required.html
  214. +111 −0 ghostwriter/templates/base.html.cookiecutter
  215. +292 −0 ghostwriter/templates/base_generic.html
  216. +64 −0 ghostwriter/templates/base_generic_empty.html
  217. +15 −0 ghostwriter/templates/confirm_delete.html
  218. +81 −0 ghostwriter/templates/index.html
  219. +30 −0 ghostwriter/templates/note_form.html
  220. 0 ghostwriter/templates/templatetags/__init__.py
  221. +12 −0 ghostwriter/templates/templatetags/check_group.py
  222. +36 −0 ghostwriter/templates/users/user_detail.html
  223. +17 −0 ghostwriter/templates/users/user_form.html
  224. 0 ghostwriter/users/__init__.py
  225. +16 −0 ghostwriter/users/adapters.py
  226. +60 −0 ghostwriter/users/admin.py
  227. +13 −0 ghostwriter/users/apps.py
  228. +30 −0 ghostwriter/users/forms.py
  229. +51 −0 ghostwriter/users/migrations/0001_initial.py
  230. +21 −0 ghostwriter/users/migrations/0002_auto_20190729_1749.py
  231. 0 ghostwriter/users/migrations/__init__.py
  232. +16 −0 ghostwriter/users/models.py
  233. 0 ghostwriter/users/tests/__init__.py
  234. +27 −0 ghostwriter/users/tests/factories.py
  235. +40 −0 ghostwriter/users/tests/test_forms.py
  236. +8 −0 ghostwriter/users/tests/test_models.py
  237. +23 −0 ghostwriter/users/tests/test_urls.py
  238. +52 −0 ghostwriter/users/tests/test_views.py
  239. +14 −0 ghostwriter/users/urls.py
  240. +50 −0 ghostwriter/users/views.py
  241. +45 −0 local.yml
  242. +6 −0 locale/README.rst
  243. +30 −0 manage.py
  244. +66 −0 merge_production_dotenvs_in_dotenv.py
  245. +62 −0 production.yml
  246. +2 −0 pytest.ini
  247. +28 −0 requirements/base.txt
  248. +28 −0 requirements/local.txt
  249. +11 −0 requirements/production.txt
  250. +21 −0 setup.cfg
@@ -0,0 +1,5 @@
[run]
include = ghostwriter/*
omit = *migrations*, *tests*
plugins =
django_coverage_plugin
@@ -0,0 +1,4 @@
.*
!.coveragerc
!.env
!.pylintrc
@@ -0,0 +1,33 @@
# http://editorconfig.org

root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
trim_trailing_whitespace = true

[*.{py,rst,ini}]
indent_style = space
indent_size = 4

[*.py]
line_length=120
known_first_party=ghostwriter
multi_line_output=3
default_section=THIRDPARTY

[*.{html,css,scss,json,yml}]
indent_style = space
indent_size = 2

[*.md]
trim_trailing_whitespace = false

[Makefile]
indent_style = tab

[nginx.conf]
indent_style = space
indent_size = 2
@@ -0,0 +1,30 @@
# General
# ------------------------------------------------------------------------------
USE_DOCKER=yes
IPYTHONDIR=/app/.ipython
DJANGO_ACCOUNT_ALLOW_REGISTRATION=False
DJANGO_ACCOUNT_EMAIL_VERIFICATION=none

# QCluster
# ------------------------------------------------------------------------------
QCLUSTER_NAME=soar
# QCLUSTER_CONNECTION=

# Virustotal
# ------------------------------------------------------------------------------
VIRUSTOTAL_API_KEY="XXXXXX"

# Slack
# ------------------------------------------------------------------------------
SLACK_ENABLE=False
SLACK_EMOJI=":ghost:"
SLACK_CHANNEL="#ghostwriter"
SLACK_ALERT_TARGET="#ghostwriter"
SLACK_USERNAME="ghost"
SLACK_URL="https://hooks.slack.com/services/<your_webhook_url>"

# Company Info
# ------------------------------------------------------------------------------
COMPANY_NAME=Ghostwriter
COMPANY_TWITTER=@ghostwriter
COMPANY_EMAIL=info@ghostwriter.local
@@ -0,0 +1,7 @@
# PostgreSQL
# ------------------------------------------------------------------------------
POSTGRES_HOST=postgres
POSTGRES_PORT=5432
POSTGRES_DB=ghostwriter
POSTGRES_USER=postgres
POSTGRES_PASSWORD=postgres
@@ -0,0 +1,61 @@
# General
# ------------------------------------------------------------------------------
# DJANGO_READ_DOT_ENV_FILE=True
DJANGO_SETTINGS_MODULE=config.settings.production
DJANGO_SECRET_KEY=changeme
DJANGO_ADMIN_URL=admin/
# DJANGO_ALLOWED_HOSTS=.ghostwriter.local

# Security
# ------------------------------------------------------------------------------
# TIP: better off using DNS, however, redirect is OK too
DJANGO_SECURE_SSL_REDIRECT=False

# Email
# ------------------------------------------------------------------------------
MAILGUN_API_KEY=
DJANGO_SERVER_EMAIL=
MAILGUN_DOMAIN=

# django-allauth
# ------------------------------------------------------------------------------
DJANGO_ACCOUNT_ALLOW_REGISTRATION=False
DJANGO_ACCOUNT_EMAIL_VERIFICATION=none

# django-compressor
# ------------------------------------------------------------------------------
COMPRESS_ENABLED=

# Gunicorn
# ------------------------------------------------------------------------------
WEB_CONCURRENCY=4


# Redis
# ------------------------------------------------------------------------------
REDIS_URL=redis://redis:6379/0


# QCluster
# ------------------------------------------------------------------------------
QCLUSTER_NAME=soar
# QCLUSTER_CONNECTION=

# Virustotal
# ------------------------------------------------------------------------------
VIRUSTOTAL_API_KEY="XXXXXX"

# Slack
# ------------------------------------------------------------------------------
SLACK_ENABLE=False
SLACK_EMOJI=":ghost:"
SLACK_CHANNEL="#ghostwriter"
SLACK_ALERT_TARGET="#ghostwriter"
SLACK_USERNAME="ghost"
SLACK_URL="https://hooks.slack.com/services/<your_webhook_url>"

# Company Info
# ------------------------------------------------------------------------------
COMPANY_NAME=Ghostwriter
COMPANY_TWITTER=@ghostwriter
COMPANY_EMAIL=info@ghostwriter.local
@@ -0,0 +1,7 @@
# PostgreSQL
# ------------------------------------------------------------------------------
POSTGRES_HOST=postgres
POSTGRES_PORT=5432
POSTGRES_DB=ghostwriter
POSTGRES_USER=changeme
POSTGRES_PASSWORD=changeme
@@ -0,0 +1 @@
* text=auto

0 comments on commit ea9c59c

Please sign in to comment.
You can’t perform that action at this time.