lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Mon, 6 Jul 2015 13:37:25 -0400 From: Vitaly Andrianov <vitalya@...com> To: <vyasevich@...il.com>, <nhorman@...driver.com>, <davem@...emloft.net>, <linux-sctp@...r.kernel.org>, <netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>, <m-karicheri2@...com> CC: Vitaly Andrianov <vitalya@...com> Subject: [PATCH] sctp: Add counters for out data chunk discards This commit adds a MIB entry for out data chunk discards. Number of outgoing SCTP DATA chunks for a SCTP association for which no problems were encountered to prevent their transmission but were discarded. Data chunks are discarded due to ungraceful closing of the SCTP association. Signed-off-by: Vitaly Andrianov <vitalya@...com> --- include/net/sctp/sctp.h | 1 + net/sctp/outqueue.c | 1 + net/sctp/proc.c | 2 ++ 3 files changed, 4 insertions(+) diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h index ce13cf2..fd806ea 100644 --- a/include/net/sctp/sctp.h +++ b/include/net/sctp/sctp.h @@ -216,6 +216,7 @@ enum { SCTP_MIB_IN_PKT_BACKLOG, SCTP_MIB_IN_PKT_DISCARDS, SCTP_MIB_IN_DATA_CHUNK_DISCARDS, + SCTP_MIB_OUT_DATA_CHUNK_DISCARDS, __SCTP_MIB_MAX }; diff --git a/net/sctp/outqueue.c b/net/sctp/outqueue.c index 7e8f0a1..dc1a40f 100644 --- a/net/sctp/outqueue.c +++ b/net/sctp/outqueue.c @@ -315,6 +315,7 @@ int sctp_outq_tail(struct sctp_outq *q, struct sctp_chunk *chunk) case SCTP_STATE_SHUTDOWN_RECEIVED: case SCTP_STATE_SHUTDOWN_ACK_SENT: /* Cannot send after transport endpoint shutdown */ + SCTP_INC_STATS(net, SCTP_MIB_OUT_DATA_CHUNK_DISCARDS); error = -ESHUTDOWN; break; diff --git a/net/sctp/proc.c b/net/sctp/proc.c index 0697eda..1a10b81 100644 --- a/net/sctp/proc.c +++ b/net/sctp/proc.c @@ -67,6 +67,8 @@ static const struct snmp_mib sctp_snmp_list[] = { SNMP_MIB_ITEM("SctpInPktBacklog", SCTP_MIB_IN_PKT_BACKLOG), SNMP_MIB_ITEM("SctpInPktDiscards", SCTP_MIB_IN_PKT_DISCARDS), SNMP_MIB_ITEM("SctpInDataChunkDiscards", SCTP_MIB_IN_DATA_CHUNK_DISCARDS), + SNMP_MIB_ITEM("SctpOutDataChunkDiscards", + SCTP_MIB_OUT_DATA_CHUNK_DISCARDS), SNMP_MIB_SENTINEL }; -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists