Err when fetching VolumeSnapshotContent image from GCE API can result in nil-ptr dereference crash
pwschuurman opened this issue · 0 comments
pwschuurman commented
In ListSnapshots, we properly wrap an error from the GCE API when an error is encountered when fetching a snapshot source from the GCE API. For image snapshot source, this is not properly wrapped (only 404 errors are wrapped). This can result in a nil-ptr dereference, causing the driver to crash.
Narrowing down the list of errors for the image snapshot case (which does have a correct logging) indicates that this could fail for the following reasons. These are all valid and likely scenarios that should result in error propagation.
- 403 Forbidden / Quota Exceeded
- 503 Unavailable
- 400 Invalid Argument