mirror of
https://github.com/tiennm99/coolify.git
synced 2026-08-20 06:23:23 +00:00
fix(security): encrypt GitLab webhook token and mask input
Webhook secret was stored and shown as plaintext. Use a password field, encrypt at rest (with legacy plaintext read support), and look up tokens via findByWebhookToken so encrypted values still authenticate webhooks.
This commit is contained in:
@@ -103,7 +103,7 @@ class Gitlab extends Controller
|
||||
], 401);
|
||||
}
|
||||
|
||||
$gitlab_app = GitlabApp::where('webhook_token', $x_gitlab_token)->first();
|
||||
$gitlab_app = GitlabApp::findByWebhookToken($x_gitlab_token);
|
||||
if (! $gitlab_app) {
|
||||
auditLogWebhookFailure('gitlab', 'invalid_token', [
|
||||
'event' => $object_kind,
|
||||
|
||||
Reference in New Issue
Block a user