Underwear is a base layer so should be made from a material which is quick drying, will wick perspiration away from the body and is unlikely to chaff.
It is a good investment to go for a technical material (synthetic-fibre) that meets these criteria.
Avoid cotton, it absorbs and retains moisture.
The underpants shown are made from a polyamide and fit the criteria perfectly. They were obtained from a local department store and cost about £8 . They performed superbly and in warmer weather, could be rinsed through and were dry by the morning.
Unless small chested enough to go bra-less, ladies should invest in a couple of good sports bras.
One issue women sometimes have to contend with is the bra strap rubbing on the collar bone due to pressure from the rucksack straps. This can usually be countered by moving the bra-strap further away from the neck so that it rests on a less prominent part of the collar bone.