You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Since the introduction of the GPG commit validation feature in commit 14fe901, getting branch information through the API causes a nil pointer dereference for unsigned commits.
The originating cause is located in routers/api/v1/convert/convert.go. Because the commit is not signed (verif.Verified is false), c.Signature is not initialized and cause the error.
There needs to be an appropriate safe guard for unsigned commits.
The text was updated successfully, but these errors were encountered:
curl -v --header "Authorization: token d716e7f20bbcbf59f9a4cf9e6e2564b6152a8b7d" https://try.gitea.io/api/v1/repos/test/test01/branches
Description
Since the introduction of the GPG commit validation feature in commit 14fe901, getting branch information through the API causes a nil pointer dereference for unsigned commits.
The originating cause is located in routers/api/v1/convert/convert.go. Because the commit is not signed (
verif.Verified
isfalse
),c.Signature
is not initialized and cause the error.There needs to be an appropriate safe guard for unsigned commits.
The text was updated successfully, but these errors were encountered: