[backport-1.7]: harbor: admin authentication broken

A solution for issue #4416 (closed) needs to be backported to 1.7.x