diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-27 21:32:33 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-12-27 21:32:33 +0000 |
commit | 025dbe3aa585e4002946d2bb80cba88fa15337b3 (patch) | |
tree | 3b2bd4fd9721d261bae592c6609285aa04a37160 /src/modules | |
parent | 5e1a481ce63eb217492937b84117a1bf5c44b4f2 (diff) |
Check on upper bounds of base64 decode
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2679 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_spanningtree.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp index 4cfff58a0..036f50617 100644 --- a/src/modules/m_spanningtree.cpp +++ b/src/modules/m_spanningtree.cpp @@ -1247,7 +1247,7 @@ class TreeSocket : public InspSocket if ((ret.substr(0,7) != "ERROR :") && (ret.substr(0,6) != "CAPAB ")) { int nbytes = from64tobits(out, ret.c_str(), 1024); - if (nbytes > 0) + if ((nbytes > 0) && (nbytes < 1024)) { log(DEBUG,"m_spanningtree: decrypt %d bytes",nbytes); ctx->Decrypt(out, result, nbytes, 0); |