The man, apparently motivated by a judicial grievance, initially tried to take hostage a group of passengers on the train bound for the southwestern city of Toulouse from the Atlantic port of La Rochelle.
But 15 passengers on the coach were able to get off when the train stopped at the city of Bordeaux, and the hostage-taker held only the woman in her forties.
According to an official involved in the release and speaking on condition of anonymity, the woman is the wife of a senior security official in the northwestern Normandy region.
The hostage was released after about two hours and the attacker detained by police SWAT units, a top security official said.
The woman appeared relaxed as rescue workers attended to her.
Several high-ranking local officials were dispatched to the scene during the brief incident and a security deployment was visible around the station but access to the platforms were not restricted and train traffic continued.