Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

生成payload时,paramsCombination函数有拷贝问题 #509

Open
jayus0821 opened this issue Apr 7, 2022 · 1 comment
Open

生成payload时,paramsCombination函数有拷贝问题 #509

jayus0821 opened this issue Apr 7, 2022 · 1 comment

Comments

@jayus0821
Copy link
Contributor

以命令注入插件为例
new_data = copy.deepcopy(data)应该放在for循环下,源代码在for循环外,导致result添加一组payload之后,下一次for循环,把上一组的new_data修改掉了,最后所有payload都是同一个,其实根本没有遍历payload.
`def paramsCombination(self, data: dict, place=PLACE.GET, url_flag={}, hint=POST_HINT.NORMAL, urlsafe='/\'):
result = []
payloads = url_flag.keys()

    for spli in ['', ';', "&&", "|"]:
        if place == PLACE.POST:
            if hint == POST_HINT.NORMAL:
                for key, value in data.items():
                    for payload in payloads:
                        new_data = copy.deepcopy(data)
                        print("payload : ",payload)
                        new_data[key] = spli + payload  #...
                        print("new_data : ",new_data)
                        print((key, value, payload, new_data, url_flag[payload]))
                        result.append((key, value, payload, new_data, url_flag[payload]))`
@boy-hack
Copy link
Member

欢迎提交pr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants