INNER CODE UNIT · Python
lambda_dir
cisco-open/forge · fuzz/splunk_stuck_dispatcher_fuzzer.py:31
lambda_dir = repo_root / lambda_path
if lambda_dir.exists():
sys.path.insert(0, str(lambda_dir))
def _event(body: str, content_type: str, *, encoded: bool) -> dict[str, Any]:
if encoded:
body = base64.b64encode(body.encode('utf-8')).decode('ascii')
return {
'headers': {
'content-type': content_type,
'user-agent': 'clusterfuzzlite',
},
'body': body,
'isBase64Encoded': encoded,
'pathParameters': {'token': body[:128]},
'requestContext': {