diff options
author | djm@openbsd.org <djm@openbsd.org> | 2016-10-11 21:47:45 +0000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2016-10-13 18:55:25 +1100 |
commit | 39af7b444db28c1cb01b7ea468a4f574a44f375b (patch) | |
tree | fcfba47f83bd07ba4ee90fc5dc4b2a641c412075 /packet.h | |
parent | ec165c392ca54317dbe3064a8c200de6531e89ad (diff) |
upstream commit
Add a per-packet input hook that is called with the
decrypted packet contents. This will be used for fuzzing; ok markus@
Upstream-ID: a3221cee6b1725dd4ae1dd2c13841b4784cb75dc
Diffstat (limited to 'packet.h')
-rw-r--r-- | packet.h | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -1,4 +1,4 @@ -/* $OpenBSD: packet.h,v 1.73 2016/09/30 09:19:13 markus Exp $ */ +/* $OpenBSD: packet.h,v 1.74 2016/10/11 21:47:45 djm Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> @@ -78,6 +78,9 @@ struct ssh { void *app_data; }; +typedef int (ssh_packet_hook_fn)(struct ssh *, struct sshbuf *, + u_char *, void *); + struct ssh *ssh_alloc_session_state(void); struct ssh *ssh_packet_set_connection(struct ssh *, int, int); void ssh_packet_set_timeout(struct ssh *, int, int); @@ -88,6 +91,8 @@ int ssh_packet_get_connection_in(struct ssh *); int ssh_packet_get_connection_out(struct ssh *); void ssh_packet_close(struct ssh *); void ssh_packet_set_encryption_key(struct ssh *, const u_char *, u_int, int); +void ssh_packet_set_input_hook(struct ssh *, ssh_packet_hook_fn *, void *); + int ssh_packet_is_rekeying(struct ssh *); void ssh_packet_set_protocol_flags(struct ssh *, u_int); u_int ssh_packet_get_protocol_flags(struct ssh *); |