diff --git a/src/caosdb/common/models.py b/src/caosdb/common/models.py
index 5a2e9cd3b2506ac1c74d967f675d963e12e9b4e5..4dadceac6208aef0d3ef56f16f336c9579f6ca2e 100644
--- a/src/caosdb/common/models.py
+++ b/src/caosdb/common/models.py
@@ -145,6 +145,10 @@ class Entity(object):
 
         return self._wrapped_entity.size
 
+    @size.setter
+    def size(self, new_size):
+        self._size = new_size if new_size is None else int(new_size)
+
     @property
     def id(self):
         if self.__id is not None:
@@ -193,14 +197,24 @@ class Entity(object):
 
         return self._wrapped_entity.description
 
-    @property
-    def checksum(self):
-        return self._checksum
-
     @description.setter
     def description(self, new_description):
         self.__description = new_description
 
+    @property
+    def checksum(self):
+        if self._checksum is not None:
+            return self._checksum
+
+        if self._wrapped_entity is None:
+            return None
+
+        return self._wrapped_entity._checksum
+
+    @checksum.setter
+    def checksum(self, new_checksum):
+        self._checksum = new_checksum
+
     @property
     def unit(self):
         if self.__unit is not None or self._wrapped_entity is None:
@@ -932,8 +946,8 @@ class Entity(object):
         if self.file is not None and local_serialization:
             xml.set("file", self.file)
 
-        if self._checksum is not None:
-            xml.set("checksum", self._checksum)
+        if self.checksum is not None:
+            xml.set("checksum", self.checksum)
 
         if self.size is not None:
             xml.set("size", str(self.size))
@@ -1780,7 +1794,7 @@ class File(Record):
         return Entity.to_xml(self, xml=xml, add_properties=add_properties,
                              local_serialization=local_serialization)
 
-    def download(self, target=None):
+    def download(self, target=None, check_hash=True):
         """Download this file-entity's actual file from the file server. It
         will be stored to the target or will be hold as a temporary file.
 
@@ -1795,7 +1809,7 @@ class File(Record):
             file_ = NamedTemporaryFile(mode='wb', delete=False)
         checksum = File.download_from_path(file_, self.path)
 
-        if self._checksum is not None and self._checksum.lower() != checksum.hexdigest().lower():
+        if check_hash and self.checksum is not None and self.checksum.lower() != checksum:
             raise ConsistencyError(
                 "The downloaded file had an invalid checksum. Maybe the download did not finish?")
 
@@ -1816,7 +1830,11 @@ class File(Record):
             data = response.read(8000)
         target_file.close()
 
-        return checksum
+        return checksum.hexdigest().lower()
+
+    @staticmethod
+    def sha512(file):
+        return File._get_checksum_single_file(file)
 
     @staticmethod
     def _get_checksum(files):
@@ -3398,7 +3416,10 @@ class Container(list):
                     randint(0, sys.maxsize)), filename=entity.thumbnail)
                 part.filename = entity._upload + ".thumbnail"
                 http_parts.append(part)
+        elif isinstance(entity, File) and hasattr(entity, "file") and entity.file is None:
+            entity._upload = None
         else:
+            entity._upload = None
             entity._checksum = None
 
     def insert(self, strict=False, raise_exception_on_error=True,