diff --git a/jitsimod/templates/jitsi/room.html b/jitsimod/templates/jitsi/room.html
index 905fc51b29dc45b74775f54b7ebf7be8dfbb6b3f..4f458fc9827e671f2eb409f3f89a72bd68b25aaf 100644
--- a/jitsimod/templates/jitsi/room.html
+++ b/jitsimod/templates/jitsi/room.html
@@ -77,7 +77,7 @@
 			<div class="w3-bar-item w3-right w3-right-align">
 				<span>Uploaded: {{ video.created_at|date:"d.m.Y" }}</span><br/>
 				<form id="video-deleteform-{{ video.id }}" action="?" method="post">{% csrf_token %}<input type="hidden" name="deleterecording" value="{{ video.id }}" /></form>
-				<span><a href="#" onclick='if(confirm("Do you really want to delete this file?")) document.getElementById("video-deleteform-{{ video.id }}").submit();' class='w3-text-red'>Delete</a>{% if video.masterfile %} | <a href="{{ MEDIA_URL }}{{ video.masterfile }}?key={{ video.key }}&timestamp={{ video.created_at|date:'U' }}" download>Download</a>{% endif %}</span>
+				<span><a href="#" onclick='if(confirm("Do you really want to delete this file?")) document.getElementById("video-deleteform-{{ video.id }}").submit();' class='w3-text-red'>Delete</a>{% if video.masterfile %} | <a href="{{ MEDIA_URL }}{{ video.masterfile }}?key={{ video.key }}&timestamp={{ video.created_at|date:'U' }}&filename={{ video.name }}" download>Download</a>{% endif %}</span>
 			</div>
 		</li>
 		{% endfor %}
diff --git a/videos/models.py b/videos/models.py
index 9f54adcb96e6274853d8b1d3b94720dc10f263a0..6cf5551b5ed26aacd95e370613597a475277192f 100755
--- a/videos/models.py
+++ b/videos/models.py
@@ -4,6 +4,7 @@ from django.conf import settings
 import secrets
 import datetime
 import os
+import re
 import time
 
 def random_key(i):
@@ -160,6 +161,13 @@ class Video(MetaVideo):
     description = models.TextField(blank=True)
     length = models.DecimalField(null=True, blank=True, decimal_places=3, max_digits=10)
 
+    def clean_filename(self):
+        if isinstance(self, str):
+            toclean = self
+        else:
+            toclean = self.course.title + " - " + (self.name if self.name else str(self.id)) + os.path.splitext(self.masterfile.name)[1]
+        return re.sub(r'[^A-Za-z_0-9,.\- ]', '', toclean).replace(' ', '%20')
+
     def original_upload_path(self, filename):
         extension = filename[::-1].split('.', 1)[0][::-1]
         return os.path.join(self.course.course_path(), 'originals', '{}.{}'.format(int(time.time()), extension))
diff --git a/videos/templates/course.html b/videos/templates/course.html
index 2bedf00b1f0baa02f6fb2810c54f9cc882cd9852..ddc3fbf9ae86b7395fa3904d36a28e8abdd1ae4a 100755
--- a/videos/templates/course.html
+++ b/videos/templates/course.html
@@ -44,7 +44,7 @@
 			<div class="w3-bar-item w3-right w3-right-align">
 				<span>Uploaded: {{ video.created_at|date:"d.m.Y" }}</span><br/>
 				{% if is_lecturer %}<form id="video-deleteform-{{ video.id }}" action="/delete" method="post">{% csrf_token %}<input type="hidden" name="type" value="video" /><input type="hidden" name="video" value="{{ video.id }}" /></form>{% endif %}
-				<span>{% if is_lecturer %}<a href="/getlog?video={{ video.id }}" class="w3-text-blue">Log</a> | <a href="#" onclick='if(confirm("Do you really want to delete this file?")) document.getElementById("video-deleteform-{{ video.id }}").submit();' class='w3-text-red'>Delete</a>{% if video.masterfile %} | {% endif %}{% endif %}{% if video.masterfile %}<a href="{{ MEDIA_URL }}{{ video.masterfile }}?key={{ video.key }}&timestamp={{ video.created_at|date:'U' }}" download>Download</a>{% endif %}</span>
+				<span>{% if is_lecturer %}<a href="/getlog?video={{ video.id }}" class="w3-text-blue">Log</a> | <a href="#" onclick='if(confirm("Do you really want to delete this file?")) document.getElementById("video-deleteform-{{ video.id }}").submit();' class='w3-text-red'>Delete</a>{% if video.masterfile %} | {% endif %}{% endif %}{% if video.masterfile %}<a href="{{ MEDIA_URL }}{{ video.masterfile }}?key={{ video.key }}&timestamp={{ video.created_at|date:'U' }}&filename={{ video.clean_filename }}" download>Download</a>{% endif %}</span>
 				{% if is_lecturer %}<br /><span>Views: {{ video.views }}</span>{% endif %}
 			</div>
 		</li>
diff --git a/videos/views.py b/videos/views.py
index 50602df8ff5094b248d5726c9569ced564ef38e2..5ef841abbe63484824b7c7106889e162a4384bed 100755
--- a/videos/views.py
+++ b/videos/views.py
@@ -166,7 +166,8 @@ def cdn(request, path):
     if not hosts:
         raise Exception("No CDN hosts available!")
     host = random.choice(hosts).url.rstrip('/')
-    redir = redirect("{}/{}?key={}&timestamp={}".format(host, path, request.GET.get('key'), request.GET.get('timestamp')))
+    arg_filename = '&filename={}'.format(Video.clean_filename(request.GET.get('filename'))) if (request.GET.get('filename') is not None) else ''
+    redir = redirect("{}/{}?key={}&timestamp={}{}".format(host, path, request.GET.get('key'), request.GET.get('timestamp'), arg_filename))
     if path.endswith(".vtt"):
         redir["Content-Type"] = "text/vtt; charset=utf-8";
     redir["Access-Control-Allow-Origin"] = "https://lectures.fslab.de"