1
mirror of https://github.com/rapid7/metasploit-payloads synced 2024-11-20 14:39:22 +01:00

use the correct length for copying arguments, fixes #3526, thanks mihi!

git-svn-id: file:///home/svn/framework3/trunk@11700 4d416f70-5f16-0410-b530-b9f4589650da
This commit is contained in:
James Lee 2011-02-02 21:26:29 +00:00
parent bc2d317ae0
commit 1ae9217a57

View File

@ -21,7 +21,7 @@ public class stdapi_sys_process_execute implements Command {
StringTokenizer st = new StringTokenizer(argsString);
String[] cmdarray = new String[st.countTokens() + 1];
cmdarray[0] = cmd;
for (int i = 0; i < st.countTokens(); i++) {
for (int i = 0; i < cmdarray.length - 1; i++) {
cmdarray[i + 1] = st.nextToken();
}
int flags = request.getIntValue(TLVType.TLV_TYPE_PROCESS_FLAGS);