The wicked Balam wanted to curse the Jewish people but when he saw their modesty and fidelity he could only bless them. What did he see? He saw their tents set up in a way as to give each one privacy. There was no direct line of sight from one tent into another. He saw that they were organized according to their tribes, which was possible because of marital fidelity.
This is followed by the prophecy of Moshiach's coming.
What lesson can we take from here? How does it connect to Moshiach?
Many are unaware that the laws of modesty apply to both men and women. It covers modesty in speech, dress, action and thought.
We also have laws of appropriate behavior between men and women.
It is these laws that has been our protection and makes us special and holy.
We find these laws difficult because they go against nature.
It is natural for a man to have inappropriate thoughts. Which can bring to immodest speech and actions.
While men love dress codes and uniforms it goes against the grain and is totally unnatural to women. To women, their dress is an expression of how they feel inside. If the dress code is not how they feel, it feels like a lie.
To this we have a two step plan. First, laws to set boundaries and safeguards. Second, to work on our inside so it resembles the Jewish spirit.
Don't think that this means that you have to be a prude or that you need to dress in shmattes. Rather, to become beautiful and dignified within and allow that to be expressed in thought, speech, action and dress.
A Jewish man is meant to be a light of decency and a living example to the world around him.
A Jewish woman is meant to be a bas melech, a princess, beautiful and dignified. Her presence effecting her surroundings.
When we act with modesty and fidelity we are in a position to change the world around us. We become as Hashem's ambassadors to make His presence known, accepted and welcome to all. It is the foundation upon which our Torah and Mitzvahs stand. It protects from our worst enemies because we are protected when we are Hashem's ambassadors. Finally, it is the basis and starting point of our positive effect on the world that will bring Moshiach.