Eg- He took advantage of the enemies weaknesses.
How about "to cash in on"?
"Play on (or upon)" could also do the trick, as well as the more formal -- yet idiomatic -- "avail oneself of" and "turn...to (good) account".
He played on his enemies' weaknesses, surprised them when they thought they couldn't be misled. source
Clever enough to discern the causes necessitating the cessation of treaty or war with an enemy, or to lie in wait keeping treaties, obligations and pledges, or to avail himself of his enemies' weak points, making jokes with no loss of dignity or secrecy... source
They availed themselves of the weaknesses, the selfishness and the self-interest of man... source
The politician of today knows men, and he knows how to turn their weaknesses to account. source
Exploited means exactly what you are asking.
He exploited the dissension in the enemy ranks and crashed through their lines.
It is not idiomatic, though. It is an exact definition.
If you are looking for an idiom (like your title says), rather than just a word that means the same thing, this answer may be helpful.
First, note that take advantage of is already considered to be an idiom (as indicate by The Free Dictionary section on idioms).
Another is strike while the iron is hot, meaning
When you have an opportunity to do something, do it before you lose your chance.
This comes from forging iron. Obviously, if you forge hot iron, you want to strike while the iron is hot, as describe at phrase finder:
Act decisively and take your opportunities when they arise.
The expression is recorded in Richard Edwards', The excellent comedie of two the moste faithfullest freendes, Damon and Pithias, circa 1566
I haue plied the Haruest, and stroke when the Yron was hotte.
Using it in the context you provided:
Noticing that his enemy was traveling through a gorge, he decided now was the time to strike, while the iron was hot.
He capitalized on the enemies weaknesses.
Another option for you is he took them for a ride.
Implicit in the idiom is that they didn't want to go.