private void SMB2CompressionTest(CompressionAlgorithm[] compressionAlgorithms, bool enableEncryption, CompressionTestVariant variant)
        {
            uint   treeId;
            FILEID fileId;

            CreateTestFile(compressionAlgorithms, enableEncryption, out treeId, out fileId);

            var instances = CompressionTestRunner.Generate(variant);

            foreach (var instance in instances)
            {
                instance.Run(client, treeId, fileId);
            }

            client.Close(treeId, fileId);
            client.TreeDisconnect(treeId);
            client.LogOff();
        }
Beispiel #2
0
        private void SMB2CompressionTest(CompressionAlgorithm[] compressionAlgorithms, CompressionTestVariant variant, bool enableEncryption = false, bool enableChainedCompression = false)
        {
            uint   treeId;
            FILEID fileId;

            if (!enableChainedCompression)
            {
                compressionAlgorithms = Smb2Utility.GetSupportedCompressionAlgorithms(compressionAlgorithms);
            }

            CreateTestFile(compressionAlgorithms, enableEncryption, out treeId, out fileId, enableChainedCompression);

            var instances = CompressionTestRunner.Generate(compressionAlgorithms, variant);

            foreach (var instance in instances)
            {
                instance.Run(client, treeId, fileId);
            }

            client.Close(treeId, fileId);
            client.TreeDisconnect(treeId);
            client.LogOff();
        }