[pgsqlclient-checkins] pgsqlclient_10/Mono.Security.Protocol.Tls/Mono.Security.Protocol.Tls CipherSu
Status: Inactive
Brought to you by:
carlosga_fb
Update of /cvsroot/pgsqlclient/pgsqlclient_10/Mono.Security.Protocol.Tls/Mono.Security.Protocol.Tls In directory sc8-pr-cvs1:/tmp/cvs-serv25276 Modified Files: CipherSuite.cs TlsCipherSuiteFactory.cs TlsSslCipherSuite.cs Log Message: no message Index: CipherSuite.cs =================================================================== RCS file: /cvsroot/pgsqlclient/pgsqlclient_10/Mono.Security.Protocol.Tls/Mono.Security.Protocol.Tls/CipherSuite.cs,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** CipherSuite.cs 28 Oct 2003 16:13:16 -0000 1.4 --- CipherSuite.cs 3 Nov 2003 20:34:30 -0000 1.5 *************** *** 255,259 **** cs.WriteByte((byte)paddingLength); } ! //cs.FlushFinalBlock(); cs.Close(); --- 255,259 ---- cs.WriteByte((byte)paddingLength); } ! // cs.FlushFinalBlock(); cs.Close(); *************** *** 275,278 **** --- 275,280 ---- // Calculate padding_length paddingLength = buffer[buffer.Length - 1]; + + /* Review this that is valid way for TLS1 but not for SSL3 for (int i = (buffer.Length - 1); i > (buffer.Length - (paddingLength + 1)); i--) { *************** *** 283,286 **** --- 285,289 ---- } } + */ fragmentSize = (buffer.Length - (paddingLength + 1)) - HashSize; Index: TlsCipherSuiteFactory.cs =================================================================== RCS file: /cvsroot/pgsqlclient/pgsqlclient_10/Mono.Security.Protocol.Tls/Mono.Security.Protocol.Tls/TlsCipherSuiteFactory.cs,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** TlsCipherSuiteFactory.cs 3 Nov 2003 19:41:34 -0000 1.7 --- TlsCipherSuiteFactory.cs 3 Nov 2003 20:34:30 -0000 1.8 *************** *** 121,126 **** // Supported ciphers ! // scs.Add((0x00 << 0x08) | 0x0A, "SSL_RSA_WITH_3DES_EDE_CBC_SHA", "3DES", "SHA1", false, true, 24, 24, 168, 8, 8); ! // scs.Add((0x00 << 0x08) | 0x09, "SSL_RSA_WITH_DES_CBC_SHA", "DES", "SHA1", false, true, 8, 8, 56, 8, 8); scs.Add((0x00 << 0x08) | 0x05, "SSL_RSA_WITH_RC4_128_SHA", "RC4", "SHA1", false, false, 16, 16, 128, 0, 0); scs.Add((0x00 << 0x08) | 0x04, "SSL_RSA_WITH_RC4_128_MD5", "RC4", "MD5", false, false, 16, 16, 128, 0, 0); --- 121,126 ---- // Supported ciphers ! scs.Add((0x00 << 0x08) | 0x0A, "SSL_RSA_WITH_3DES_EDE_CBC_SHA", "3DES", "SHA1", false, true, 24, 24, 168, 8, 8); ! scs.Add((0x00 << 0x08) | 0x09, "SSL_RSA_WITH_DES_CBC_SHA", "DES", "SHA1", false, true, 8, 8, 56, 8, 8); scs.Add((0x00 << 0x08) | 0x05, "SSL_RSA_WITH_RC4_128_SHA", "RC4", "SHA1", false, false, 16, 16, 128, 0, 0); scs.Add((0x00 << 0x08) | 0x04, "SSL_RSA_WITH_RC4_128_MD5", "RC4", "MD5", false, false, 16, 16, 128, 0, 0); Index: TlsSslCipherSuite.cs =================================================================== RCS file: /cvsroot/pgsqlclient/pgsqlclient_10/Mono.Security.Protocol.Tls/Mono.Security.Protocol.Tls/TlsSslCipherSuite.cs,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** TlsSslCipherSuite.cs 3 Nov 2003 18:11:54 -0000 1.9 --- TlsSslCipherSuite.cs 3 Nov 2003 20:34:30 -0000 1.10 *************** *** 112,116 **** block.Write(fragment); ! byte[] blockHash = hash.ComputeHash(block.ToArray(), 0, (int)block.Length); block.Reset(); --- 112,118 ---- block.Write(fragment); ! hash.ComputeHash(block.ToArray(), 0, (int)block.Length); ! ! byte[] blockHash = hash.Hash; block.Reset(); *************** *** 120,128 **** block.Write(blockHash); ! blockHash = hash.ComputeHash(block.ToArray(), 0, (int)block.Length); block.Reset(); ! return blockHash; } --- 122,130 ---- block.Write(blockHash); ! hash.ComputeHash(block.ToArray(), 0, (int)block.Length); block.Reset(); ! return hash.Hash; } |