[Go] DataFlow modeling for wrapped/argument functions #16718
-
|
Hi, I am trying to identify why or how I could get the following dataflow from Debugging using partial flow, I can see I somewhat expected CodeQL to resolve that wrapping/function passing automatically, but since it didn't here I question if it is a bug or simply something missing from my query. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
No, this doesn't work at the moment in Go. This scenario was successfully implemented a few months ago for Java, but we haven't had the time yet to port the solution to the Go QL library. To work around the problem, you would need to use the If you are still struggling to get this to do what you want, post your implementation of |
Beta Was this translation helpful? Give feedback.
No, this doesn't work at the moment in Go. This scenario was successfully implemented a few months ago for Java, but we haven't had the time yet to port the solution to the Go QL library.
To work around the problem, you would need to use the
isAdditionalFlowSteppredicate ofMyFlowImplto implement logic such as, for a call towrapExecWithRetry, anything that flows to areturnnode of its argument also flows to the callsite ofwrapExecWithRetry-- or, to make that more general, replacewrapExecWithRetrywith any function with a lambda parameter where the return value of that lambda is itself returned.If you are still struggling to get this to do what you want, post your implementation of
i…