The insecurity is your own. You fear judgement, and honest information is a prerequisite for good judgement.
You lied because you were insecure in the ability of your relationship, reputation, and value to your partner being sufficient to carry you past your revealed history.