The Thirteen Gun Salute by Patrick O'Brian
Captain Jack Aubrey sets sail for the South China Sea with a new lease on life. Following his dismissal from the Royal Navy (a false accusation), he has earned reinstatement through his daring exploits as a privateer, brilliantly chronicled in The Letter of Marque. Now he is to shepherd Stephen Maturin-his friend, ship's surgeon, and sometimes intelligence agent-on a diplomatic mission to prevent links between Bonaparte and the Malay princes which would put English merchant shipping at risk.
The journey of the Diane encompasses a great and satisfying diversity of adventures. Maturin climbs the Thousand Steps of the sacred crater of the orangutans; a killer typhoon catches Aubrey and his crew trying to work the Diane off a reef; and in the barbaric court of Pulo Prabang a classic duel of intelligence agents unfolds: the French envoys, well entrenched in the Sultan's good graces, against the savage cunning of Stephen Maturin.