                 }
     
                 return protection
-                    .open(file: file, fetcher: fetcher, credentials: credentials, allowUserInteraction: allowUserInteraction, sender: sender, onAskCredentials: self.onAskCredentials)
+                    .open(file: file, fetcher: fetcher, allowUserInteraction: allowUserInteraction, credentials: credentials, sender: sender)
                     .flatMap {
                         if let protectedFile = $0 {
                             return .success(protectedFile)

                let fetcher = try ArchiveFetcher(url: file.url, password: password, openArchive: self.openArchive)
                return .success(fetcher)
                
            } catch ArchiveError.invalidPassword where allowUserInteraction == true {
                // Attempts to recover by asking the user for its credentials
                return self.askPassword(sender: sender)
                    .flatMap { self.createFetcher(for: file, allowUserInteraction: allowUserInteraction, password: $0, sender: sender) }

            } catch {
                return .success(FileFetcher(href: "/\(file.name)", path: file.url))

        }
    }
    
    /// Unlocks any protected file with the provided Content Protections.
    private func openFile(at file: File, with fetcher: Fetcher, allowUserInteraction: Bool, credentials: String?, sender: Any?) -> Deferred<PublicationFile, Publication.OpeningError> {
        func unlock(using protections: [ContentProtection]) -> Deferred<ProtectedFile?, Publication.OpeningError> {
            return deferred {
                var protections = protections
