Develop and Download Open Source Software

Browse Subversion Repository

Diff of /branches/ssh_chacha20poly1305/ttssh2/ttxssh/ssh.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4423 by doda, Fri Apr 8 07:34:37 2011 UTC revision 4433 by doda, Mon Apr 11 00:29:12 2011 UTC
# Line 4168  void SSH2_packet_start(buffer_t *msg, un Line 4168  void SSH2_packet_start(buffer_t *msg, un
4168  // the caller is normalize_cipher_order()  // the caller is normalize_cipher_order()
4169  void SSH2_update_cipher_myproposal(PTInstVar pvar)  void SSH2_update_cipher_myproposal(PTInstVar pvar)
4170  {  {
4171          static char buf[192]; // TODO: malloc()にすべき          static char buf[512]; // TODO: malloc()にすべき
4172          int cipher;          int cipher;
4173          int len, i;          int len, i;
4174          char *c_str;          char *c_str;
# Line 4230  void SSH2_update_cipher_myproposal(PTIns Line 4230  void SSH2_update_cipher_myproposal(PTIns
4230                          case SSH2_CIPHER_CAST128_CTR:                          case SSH2_CIPHER_CAST128_CTR:
4231                                  c_str = "cast128-ctr,";                                  c_str = "cast128-ctr,";
4232                                  break;                                  break;
4233    #ifdef WITH_CAMELLIA_DRAFT
4234    #ifdef WITH_CAMELLIA_PRIVATE
4235                            case SSH2_CIPHER_CAMELLIA128_CBC:
4236                                    c_str = "camellia128-cbc,camellia128-cbc@openssh.org,";
4237                                    break;
4238                            case SSH2_CIPHER_CAMELLIA192_CBC:
4239                                    c_str = "camellia192-cbc,camellia192-cbc@openssh.org,";
4240                                    break;
4241                            case SSH2_CIPHER_CAMELLIA256_CBC:
4242                                    c_str = "camellia256-cbc,camellia256-cbc@openssh.org,";
4243                                    break;
4244                            case SSH2_CIPHER_CAMELLIA128_CTR:
4245                                    c_str = "camellia128-ctr,camellia128-ctr@openssh.org,";
4246                                    break;
4247                            case SSH2_CIPHER_CAMELLIA192_CTR:
4248                                    c_str = "camellia192-ctr,camellia192-ctr@openssh.org,";
4249                                    break;
4250                            case SSH2_CIPHER_CAMELLIA256_CTR:
4251                                    c_str = "camellia256-ctr,camellia256-ctr@openssh.org,";
4252                                    break;
4253    #else // WITH_CAMELLIA_PRIVATE
4254                            case SSH2_CIPHER_CAMELLIA128_CBC:
4255                                    c_str = "camellia128-cbc,";
4256                                    break;
4257                            case SSH2_CIPHER_CAMELLIA192_CBC:
4258                                    c_str = "camellia192-cbc,";
4259                                    break;
4260                            case SSH2_CIPHER_CAMELLIA256_CBC:
4261                                    c_str = "camellia256-cbc,";
4262                                    break;
4263                            case SSH2_CIPHER_CAMELLIA128_CTR:
4264                                    c_str = "camellia128-ctr,";
4265                                    break;
4266                            case SSH2_CIPHER_CAMELLIA192_CTR:
4267                                    c_str = "camellia192-ctr,";
4268                                    break;
4269                            case SSH2_CIPHER_CAMELLIA256_CTR:
4270                                    c_str = "camellia256-ctr,";
4271                                    break;
4272    #endif // WITH_CAMELLIA_PRIVATE
4273    #endif // WITH_CAMELLIA_DRAFT
4274                          default:                          default:
4275                                  continue;                                  continue;
4276                  }                  }
# Line 4457  static kex_algorithm choose_SSH2_kex_alg Line 4498  static kex_algorithm choose_SSH2_kex_alg
4498  static SSHCipher choose_SSH2_cipher_algorithm(char *server_proposal, char *my_proposal)  static SSHCipher choose_SSH2_cipher_algorithm(char *server_proposal, char *my_proposal)
4499  {  {
4500          SSHCipher cipher = SSH_CIPHER_NONE;          SSHCipher cipher = SSH_CIPHER_NONE;
4501          char str_cipher[16];          char str_cipher[32];
4502          ssh2_cipher_t *ptr = ssh2_ciphers;          ssh2_cipher_t *ptr = ssh2_ciphers;
4503    
4504          choose_SSH2_proposal(server_proposal, my_proposal, str_cipher, sizeof(str_cipher));          choose_SSH2_proposal(server_proposal, my_proposal, str_cipher, sizeof(str_cipher));
# Line 5902  static BOOL handle_SSH2_newkeys(PTInstVa Line 5943  static BOOL handle_SSH2_newkeys(PTInstVa
5943                                 | 1 << SSH2_CIPHER_3DES_CTR                                 | 1 << SSH2_CIPHER_3DES_CTR
5944                                 | 1 << SSH2_CIPHER_BLOWFISH_CTR                                 | 1 << SSH2_CIPHER_BLOWFISH_CTR
5945                                 | 1 << SSH2_CIPHER_CAST128_CTR                                 | 1 << SSH2_CIPHER_CAST128_CTR
5946    #ifdef WITH_CAMELLIA_DRAFT
5947                                   | 1 << SSH2_CIPHER_CAMELLIA128_CBC
5948                                   | 1 << SSH2_CIPHER_CAMELLIA192_CBC
5949                                   | 1 << SSH2_CIPHER_CAMELLIA256_CBC
5950                                   | 1 << SSH2_CIPHER_CAMELLIA128_CTR
5951                                   | 1 << SSH2_CIPHER_CAMELLIA192_CTR
5952                                   | 1 << SSH2_CIPHER_CAMELLIA256_CTR
5953    #endif // WITH_CAMELLIA_DRAFT
5954          );          );
5955          int type = (1 << SSH_AUTH_PASSWORD) | (1 << SSH_AUTH_RSA) |          int type = (1 << SSH_AUTH_PASSWORD) | (1 << SSH_AUTH_RSA) |
5956                     (1 << SSH_AUTH_TIS) | (1 << SSH_AUTH_PAGEANT);                     (1 << SSH_AUTH_TIS) | (1 << SSH_AUTH_PAGEANT);

Legend:
Removed from v.4423  
changed lines
  Added in v.4433

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26