/* * netsniff-ng - the packet sniffing beast * Copyright 2012 Markus Amend , Deutsche Flugsicherung GmbH * Subject to the GPL, version 2. * * Encapsulating Security Payload described in RFC4303 */ #include #include #include /* for ntohs() */ #include "proto.h" #include "protos.h" #include "built_in.h" #include "pkt_buff.h" struct esp_hdr { uint32_t h_spi; uint32_t h_sn; } __packed; static void esp(struct pkt_buff *pkt) { struct esp_hdr *esp_ops; esp_ops = (struct esp_hdr *) pkt_pull(pkt, sizeof(*esp_ops)); if (esp_ops == NULL) return; tprintf(" [ ESP "); tprintf("SPI (0x%x), ", ntohl(esp_ops->h_spi)); tprintf("SN (0x%x)", ntohl(esp_ops->h_sn)); tprintf(" ]\n"); } static void esp_less(struct pkt_buff *pkt) { struct esp_hdr *esp_ops; esp_ops = (struct esp_hdr *) pkt_pull(pkt, sizeof(*esp_ops)); if (esp_ops == NULL) return; tprintf(" ESP"); } struct protocol ip_esp_ops = { .key = 0x32, .print_full = esp, .print_less = esp_less, }; c94b21a8a91a76e42176685d'/> net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Lutomirski <luto@kernel.org>2016-12-12 12:54:37 -0800
committerSteve French <smfrench@gmail.com>2016-12-14 01:44:16 -0600
commit06deeec77a5a689cc94b21a8a91a76e42176685d (patch)
tree372862541646467a01b521e5e4328143036268ed /Documentation/men-chameleon-bus.txt
parent96a988ffeb90dba33a71c3826086fe67c897a183 (diff)
cifs: Fix smbencrypt() to stop pointing a scatterlist at the stack
smbencrypt() points a scatterlist to the stack, which is breaks if CONFIG_VMAP_STACK=y. Fix it by switching to crypto_cipher_encrypt_one(). The new code should be considerably faster as an added benefit. This code is nearly identical to some code that Eric Biggers suggested. Cc: stable@vger.kernel.org # 4.9 only Reported-by: Eric Biggers <ebiggers3@gmail.com> Signed-off-by: Andy Lutomirski <luto@kernel.org> Acked-by: Jeff Layton <jlayton@redhat.com> Signed-off-by: Steve French <smfrench@gmail.com>
Diffstat (limited to 'Documentation/men-chameleon-bus.txt')