puttyexp.h 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. #ifndef PUTTY_PUTTYEXP_H
  2. #define PUTTY_PUTTYEXP_H
  3. #include "defs.h"
  4. // from ssh.c
  5. struct ssh1_cipheralg;
  6. typedef const struct ssh1_cipheralg *ssh1_cipher;
  7. struct ssh2_cipheralg;
  8. typedef const struct ssh2_cipheralg *ssh2_cipher;
  9. int is_ssh(Plug plug);
  10. int get_ssh_version(Backend * be);
  11. void * get_ssh_frontend(Plug plug);
  12. const ssh1_cipher * get_cipher(Backend * be);
  13. const ssh2_cipher * get_cscipher(Backend * be);
  14. const ssh2_cipher * get_sccipher(Backend * be);
  15. const struct ssh_compressor * get_cscomp(Backend * be);
  16. const struct ssh_decompressor * get_sccomp(Backend * be);
  17. #define WINSCP_QUERY_REMMAXPKT 1
  18. #define WINSCP_QUERY_MAIN_CHANNEL 2
  19. #define WINSCP_QUERY_TIMER 3
  20. unsigned int winscp_query(Backend * be, int query);
  21. void md5checksum(const char * buffer, int len, unsigned char output[16]);
  22. typedef const struct ssh_keyalg * cp_ssh_keyalg;
  23. void get_hostkey_algs(int * count, cp_ssh_keyalg * SignKeys);
  24. void get_macs(int * count, const struct ssh2_macalg *** amacs);
  25. // from wingss.c
  26. #ifndef SSH2_GSS_OIDTYPE
  27. #include "sshgss.h"
  28. #endif
  29. // from portfwd.c
  30. int is_pfwd(Plug plug);
  31. Frontend * get_pfwd_frontend(Plug plug);
  32. // for winstore.c
  33. #include "winstuff.h"
  34. long reg_open_winscp_key(HKEY Key, const char * SubKey, HKEY * Result);
  35. long reg_create_winscp_key(HKEY Key, const char * SubKey, HKEY * Result);
  36. long reg_query_winscp_value_ex(HKEY Key, const char * ValueName,
  37. unsigned long * Reserved, unsigned long * Type, unsigned char * Data,
  38. unsigned long * DataSize);
  39. long reg_set_winscp_value_ex(HKEY Key, const char * ValueName, unsigned long Reserved,
  40. unsigned long Type, const unsigned char * Data, unsigned long DataSize);
  41. long reg_close_winscp_key(HKEY Key);
  42. // from winstore.c
  43. void putty_mungestr(const char *in, char *out);
  44. void putty_unmungestr(const char *in, char *out, int outlen);
  45. // from winnet.c
  46. void select_result(WPARAM wParam, LPARAM lParam);
  47. // from sshaes.c
  48. void call_aes_setup(void * ctx, unsigned char * key, int keylen);
  49. void call_aes_encrypt(void * ctx, unsigned int * block);
  50. void call_aes_decrypt(void * ctx, unsigned int * block);
  51. void call_aes_sdctr(unsigned char *blk, int len, void *ctx);
  52. // from winmisc.c
  53. void win_misc_cleanup();
  54. // from misc.c
  55. const char * get_putty_version();
  56. // from winsecur.c
  57. void win_secur_cleanup(void);
  58. // from sshecc.c
  59. void ec_cleanup(void);
  60. #endif