private string GenerateHash(string fileName) { var getHash = new FileHash(fileName); var hash = getHash.GenerateFileHash(); return(hash); }
private EFile LoadData(string filename) { var file = savedFiles.Find(x => x.FileName.Contains(filename)).FileLocation; var fileDetails = DBController.ReadFileDetails(file); var genHash = new FileHash($"{file}.aes"); var fullFileDetails = DBController.ReadEncryptedFileDetails(genHash.GenerateFileHash()); fullFileDetails.FileLocation = fileDetails.FileLocation; fullFileDetails.FileName = fileDetails.FileName; fullFileDetails.IsStored = fileDetails.IsStored; return(fullFileDetails); }