Hey OpenCesus :-)
I am the lead developer of Sqreen's Go agent, and some users are unfortunately experiencing integration issues when using your driver wrapper ocDriver with our SQL-injection protection.
The problem simply comes from the fact the underlying wrapped driver gets hidden and our SQL dialect detection function no longer gets the underlying driver package path.
Describe the solution you'd like
Simply define a new ocDriver method Unwrap returning the wrapped driver so that we can detect it and unwrap it:
func (d *ocDriver) Unwrap() driver.Driver {
return d.parent
}
Additional context
As this is a very common issue, I wrote a Go proposal to try to standardize the Unwrapper interface at golang/go#42460
Hey OpenCesus :-)
I am the lead developer of Sqreen's Go agent, and some users are unfortunately experiencing integration issues when using your driver wrapper
ocDriverwith our SQL-injection protection.The problem simply comes from the fact the underlying wrapped driver gets hidden and our SQL dialect detection function no longer gets the underlying driver package path.
Describe the solution you'd like
Simply define a new
ocDrivermethodUnwrapreturning the wrapped driver so that we can detect it and unwrap it:Additional context
As this is a very common issue, I wrote a Go proposal to try to standardize the
Unwrapperinterface at golang/go#42460