diff options
author | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-03-07 16:28:38 +0000 |
---|---|---|
committer | Mike Belopuhov <mikeb@cvs.openbsd.org> | 2017-03-07 16:28:38 +0000 |
commit | 4c94160c23a324643ab96b361e50479017c90786 (patch) | |
tree | ac4e2c6aceb294b95760dc33805f022320b43e51 /sys/net/pf.c | |
parent | ec56c410b88d0c8821f611698ea16c216dcc3ed2 (diff) |
Don't overwrite the flow ID once it's set
Output processing may split, encapsulate or obfuscate a single
stream which makes the changed flow ID less useful for purposes
of flow control, for instance fair sharing of bandwidth.
OK dlg
Diffstat (limited to 'sys/net/pf.c')
-rw-r--r-- | sys/net/pf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/net/pf.c b/sys/net/pf.c index f75ef912d0d..711485754dc 100644 --- a/sys/net/pf.c +++ b/sys/net/pf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pf.c,v 1.1016 2017/03/07 09:29:40 mpi Exp $ */ +/* $OpenBSD: pf.c,v 1.1017 2017/03/07 16:28:37 mikeb Exp $ */ /* * Copyright (c) 2001 Daniel Hartmeier @@ -6782,7 +6782,7 @@ done: s->key[PF_SK_STACK]->inp = pd.m->m_pkthdr.pf.inp; } - if (s) { + if (s && (pd.m->m_pkthdr.ph_flowid & M_FLOWID_VALID) == 0) { pd.m->m_pkthdr.ph_flowid = M_FLOWID_VALID | (M_FLOWID_MASK & bemtoh64(&s->id)); } |