| commit | a76ba54e2833761c46fd57cbe2486cbc38686717 | [log] [tgz] |
|---|---|---|
| author | Phil Sutter <phil@nwl.cc> | Mon Sep 24 19:25:22 2018 +0200 |
| committer | Florian Westphal <fw@strlen.de> | Tue Sep 25 16:26:20 2018 +0200 |
| tree | f0d66236a18e7e85eb4646496d34250220936242 | |
| parent | a3716cc1a501e40e26a96d78b2e1285bb081f366 [diff] |
libiptc: NULL-terminate errorname In struct chain_head, field 'name' is of size TABLE_MAXNAMELEN, hence copying its content into 'error_name' field of struct xt_error_target which is two bytes shorter may overflow. Make sure this doesn't happen by using strncpy() and set the last byte to zero. Signed-off-by: Phil Sutter <phil@nwl.cc> Signed-off-by: Florian Westphal <fw@strlen.de>