It's all about the answers!

Ask a question

Error 403 during git push


Angelo Corna (26148381) | asked Mar 07, 4:05 p.m.
I've activate the EWM-Gitlab integration on my 7.0.2 environment.

My pre-receive hook return this error during a push operation

git push
Enumerating objects: 19, done.
Counting objects: 100% (19/19), done.
Delta compression using up to 12 threads
Compressing objects: 100% (4/4), done.
Writing objects: 100% (10/10), 605 bytes | 605.00 KiB/s, done.
Total 10 (delta 2), reused 0 (delta 0), pack-reused 0
remote: GL-HOOK-ERR: VERBOSE: [EWM] [pre-receive]: Begin execution of pre-receive hook for GitLab
remote: GL-HOOK-ERR: INFO: [EWM] [pre-receive]: Found GitLab server URL set in GL_SERVER variable.
remote: GL-HOOK-ERR: INFO: [EWM] [pre-receive]: Found GitLab user's token. set in GL_SERVER variable.
remote: GL-HOOK-ERR: INFO: [EWM] [pre-receive]: Received GL_ID from GitLab server - user-2
remote: GL-HOOK-ERR: INFO: [EWM] [pre-receive]: Contacting GitLab server http://gitlab.zosdevops.com to retrieve the user id corresponding to GL_USER 2
remote: GL-HOOK-ERR: INFO: [EWM] [pre-receive]: REMOTE_USER is root
remote: GL-HOOK-ERR: VERBOSE: [EWM] [pre-receive]: Calling toolkit with arguments old_sha1=2e7c7c871e269f01cab62f30c84f2aecf7e3a22d&new_sha1=342e2ee072a52a403eebfc21f11e105685b56957&ref_name=refs%2Fheads%2Fmain&
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush ****************************************************************************
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush product_version=7.0.2 SR1iFix015
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush product_release_label=7.0.2 SR1
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush product_iteration_label=iFix015
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush product_release_artifact_version_label=7.0.2000
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush product_ifix_version=iFix015
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush build_id=EWM-SERVER-I20220731-0234
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush ****************************************************************************
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'config', 'rtc.repokey' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22576
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'config', 'rtc.repourl' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22577
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'config', 'rtc.refsExcluded4PushValidation' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22578
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'config', 'rtc.wikeywords' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22579
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'config', '--get-regexp', 'rtcwi.*.alias' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22580
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22580 code =  1 signal =  null
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: CLGitResourceProvider getConfig.spawnCb(): err = Git Error: 'null' 1:
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22579 code =  1 signal =  null
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: CLGitResourceProvider getConfig.spawnCb(): err = Git Error: 'null' 1:
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22578 code =  1 signal =  null
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: CLGitResourceProvider getConfig.spawnCb(): err = Git Error: 'null' 1:
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22577 code =  0 signal =  null
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22576 code =  0 signal =  null
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'rev-list',
remote:   '2e7c7c871e269f01cab62f30c84f2aecf7e3a22d..342e2ee072a52a403eebfc21f11e105685b56957' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22581
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'rev-list',
remote:   '342e2ee072a52a403eebfc21f11e105685b56957..2e7c7c871e269f01cab62f30c84f2aecf7e3a22d' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22582
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22581 code =  0 signal =  null
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22582 code =  0 signal =  null
remote: GL-HOOK-ERR: WARNING: [EWM] [Toolkit]: CLGitResourceProvider getCommitsBetween.spawnCb(): err = Git Error: ''
remote: GL-HOOK-ERR: WARNING: [EWM] [Toolkit]: ValidatePush There is an error in fetching rewind commits Git Error: ''
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush buildRefModel(): refModel { 'refs/heads/main':
remote:    { oldSha1: '2e7c7c871e269f01cab62f30c84f2aecf7e3a22d',
remote:      newSha1: '342e2ee072a52a403eebfc21f11e105685b56957',
remote:      refNameIx: 0,
remote:      commitsForward: [ '342e2ee072a52a403eebfc21f11e105685b56957' ],
remote:      opHint: 'commit_add' } }
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): cmd =  git args =  [ 'cat-file', '-p', '342e2ee072a52a403eebfc21f11e105685b56957' ] outputCharEncoding =  utf8
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): child pid =  22583
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: OSUtils doSpawn(): close event of child process 22583 code =  0 signal =  null
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush fetchCommitDetails(): commitSha1ToCommitInfoMap { '342e2ee072a52a403eebfc21f11e105685b56957':
remote:    { treeSha1: '949a5ae11c63432beaa2aa9a2a6ed9131242da33',
remote:      parentSha1s: [ '2e7c7c871e269f01cab62f30c84f2aecf7e3a22d' ],
remote:      author:
remote:       { name: 'angelo_corna@it.ibm.com',
remote:         email: 'angelo_corna@it.ibm.com',
remote:         timeStamp: '1709843187',
remote:         tzOffset: '+0100' },
remote:      committer:
remote:       { name: 'angelo_corna@it.ibm.com',
remote:         email: 'angelo_corna@it.ibm.com',
remote:         timeStamp: '1709843187',
remote:         tzOffset: '+0100' },
remote:      comment: 'test\n' } }
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: HTTPUtils HTTPUtils.js : Entering extractUserEmail
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: HTTPUtils HTTPUtils.js : gitUserDetails=root
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: HTTPUtils HTTPUtils.js : No @ character detected, returning gitUserDetails as is
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: HTTPUtils HTTPUtils.js : Returning gitUserDetails = root
remote: GL-HOOK-ERR: INFO:    [EWM] [Toolkit]: ValidatePush doValidateWithRTC(): data = { gitUser: 'root',
remote:   repositoryKey: 'c6ec6e650b1a46b8bcaef04ca1c1d1d',
remote:   remoteRef: [ 'refs/heads/main' ],
remote:   opHint: [ 'commit_add' ],
remote:   oldSha1: [ '2e7c7c871e269f01cab62f30c84f2aecf7e3a22d' ],
remote:   newSha1: [ '342e2ee072a52a403eebfc21f11e105685b56957' ],
remote:   commitSha1: [ '342e2ee072a52a403eebfc21f11e105685b56957' ],
remote:   commitComment: [ 'test\n' ],
remote:   committerName: [ 'angelo_corna@it.ibm.com' ],
remote:   committerEmail: [ 'angelo_corna@it.ibm.com' ],
remote:   refNameIx: [ 0 ],
remote:   wiAttrIds: [],
remote:   wiAttrIdAlias: [] }
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: ValidatePush doValidateWithRTC(): encoded data = 'gitUser=root&repositoryKey=c6ec6e650b1a46b8bcaef04ca1c1d1d1&remoteRef=refs%2Fheads%2Fmain&opHint=commit_add&oldSha1=2e7c7c871e269f01cab62f30c84f2aecf7e3a22d&newSha1=342e2ee072a52a403eebfc21f11e105685b56957&commitSha1=342e2ee072a52a403eebfc21f11e105685b56957&commitComment=test%0A&committerName=angelo_corna%40it.ibm.com&committerEmail=angelo_corna%40it.ibm.com&refNameIx=0'
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: RTC invokeRTCService(): params =  https://amc-elm11.fyre.ibm.com/ccm/service/com.ibm.team.git.common.internal.IGitOperationInvokeService/ValidatePush2 'gitUser=root&repositoryKey=c6ec6e650b1a46b8bcaef04ca1c1d1d1&remoteRef=refs%2Fheads%2Fmain&opHint=commit_add&oldSha1=2e7c7c871e269f01cab62f30c84f2aecf7e3a22d&newSha1=342e2ee072a52a403eebfc21f11e105685b56957&commitSha1=342e2ee072a52a403eebfc21f11e105685b56957&commitComment=test%0A&committerName=angelo_corna%40it.ibm.com&committerEmail=angelo_corna%40it.ibm.com&refNameIx=0'
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: RTC invokeRTCService(): status code =  403
remote: GL-HOOK-ERR:
remote: GL-HOOK-ERR: CRRTC8814E: You are not authorized to perform that Git operation.
remote: GL-HOOK-ERR: The Git operation cannot be completed because you are not authorized to perform it.
remote: GL-HOOK-ERR: In the IBM Engineering Workflow Management web client, authorize your user account by selecting the "Authorize Git Requests." If the problem persists, contact your administrator to authorize you.
remote: GL-HOOK-ERR:
remote: GL-HOOK-ERR:
remote: GL-HOOK-ERR: VERBOSE: [EWM] [Toolkit]: Utils exit(): ec =  1
To http://gitlab.zosdevops.com/ewm_integration/gitsw1.git
 ! [remote rejected] main -> main (pre-receive hook declined)
error: failed to push some refs to 'http://gitlab.zosdevops.com/ewm_integration/gitsw1.git'

I've already authorized all user and I'm not understanding the message:
CRRTC8814E: You are not authorized to perform that Git operation

How can I understand which user is not authorized?

Thanks in advance.


Comments
Don Yang commented Mar 11, 12:39 a.m.

if EWM and Gitlab have different login user, it could lead to the same error

2 answers



permanent link
Angelo Corna (26148381) | answered Mar 11, 3:58 a.m.
I think this is the case. EWM is integrated with LDAP and GitLab has a local authentication.
Is it a supported configuration?

permanent link
Don Yang (7.7k21110138) | answered Mar 11, 4:28 a.m.
According to the doc

if there is not a shared user base, you would need to have functional user id to configure webhooks or post-receive hook.

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.