zaproxy / zaproxy

The ZAP by Checkmarx Core project
https://www.zaproxy.org
Apache License 2.0
12.63k stars 2.25k forks source link

gRPC support. Not able to encode and decode gRPC messages. #8642

Open kdurolek opened 1 month ago

kdurolek commented 1 month ago

Describe the bug

ZAP is able to intercept gRPC request and response that I sent (acting as a proxy) but

  1. when I try to decode request of response message using dropdown (Body: gRPC) I always get this error "Illegal base64 character 0".
  2. when I want to prepare/modify massage myself and send it to gRPC endpoint I always get this error back grpc-status: 8 grpc-message: grpc: received message larger than max

Steps to reproduce the behavior

  1. Intercept any gRPC request in ZAP. Try to decode any request or response using body dropdown. image

image

  1. Try to prepare any gRPC request and send it. image

Expected behavior

I'm able to read and modify gRPC requests and responses

Software versions

2.15.0

Screenshots

No response

Errors from the zap.log file

No response

Additional context

No response

Would you like to help fix this issue?

kingthorin commented 1 month ago

@amitpanwar789 are you able to look into this?

kingthorin commented 1 month ago

@kdurolek could you provide the raw content?

kingthorin commented 3 weeks ago

@kdurolek could you provide the raw content?

kdurolek commented 3 weeks ago

image

kdurolek commented 3 weeks ago

Raw request exported from ZAP: issue.txt

kingthorin commented 3 weeks ago

Thanks. What were your steps exporting it raw from ZAP?

kdurolek commented 3 weeks ago

No problem. 1) I found request in zap history (also available via site tree) 2) Right-click -> Save as RAW -> Choose file name -> Save 3) I have renamed file issue.raw -> to issue.txt because I wasn't able to attach it (it was complaining about file type).

I hope it helps.