The ruling for the hajj of a person working under a contract
Is the hajj of a person working under a contract in Saudi Arabia during the hajj season valid?
There is a difference between the validity of hajj and its permissibility. Hajj is considered valid when it meets its integrals and requirements and it suffices for the obligatory hajj of Islam, if the pilgrim has not performed it before; otherwise, it is considered supererogatory [nafila].
If the contract does not permit an employee to perform hajj, and you go anyway, then you are blameworthy for breaching the terms of the contract and for the ensuing harm you incur upon yourself and others. However, in such a case, hajj is still valid it fulfills all the obligatory actions and conditions.