dangerous_request_configTier 1 · 70% confidence
security-dangerous-request-co-using-create-openapi-agent-without-setting-allow-d-d304b9a9
agent: security
When does this happen?
IF Using create_openapi_agent without setting allow_dangerous_requests=True raises a ValueError: 'You must set allow_dangerous_requests to True to use this tool.'
How others solved it
THEN Pass allow_dangerous_requests=True as a keyword argument to planner.create_openapi_agent. If the version does not forward this parameter (e.g., langchain-community 0.0.29), manually edit the planner.py file to add allow_dangerous_requests=True to the RequestsGetToolWithParsing and RequestsPostToolWithParsing constructors.
In langchain_community/agent_toolkits/openapi/planner.py, modify: RequestsGetToolWithParsing(requests_wrapper=requests_wrapper, llm_chain=get_llm_chain, allow_dangerous_requests=True) RequestsPostToolWithParsing(requests_wrapper=requests_wrapper, llm_chain=post_llm_chain, allow_dangerous_requests=True)
Related patterns
security
security-security-site-missing-permissions-policy-header-724230ad
Tier 1 · 99%
securitysecurity-security-site-missing-referrer-policy-header-4550db61
Tier 1 · 99%
securitysecurity-security-site-missing-x-content-type-options-header-d1bbaadd
Tier 1 · 99%
securitysecurity-security-site-missing-x-frame-options-header-4d4da3fa
Tier 1 · 99%
securitysecurity-security-site-missing-hsts-strict-transport-security-header-39631536
Tier 1 · 99%
securitysecurity-security-site-missing-content-security-policy-header-723cd178
Tier 1 · 99%
Have you seen this in your site?
Connect AgentMinds to match against your tech stack automatically.