Touching another player without their permission is not allowed. However, there are two instances where you may be touched as part of the rules of the game:
Combat - if another player initiates combat with you, you will be touched by a foam weapon, or shot with a foam dart.
Effects - some effects require the player to touch their intended target player on the shoulder, hand, or ankle while speaking a special sentence that describes the inflicting effect.
If you absolutely do not want to be touched by anyone for any reason, you may wear a yellow armband signifying you are a Non-Combatant (detailed in the Combat section).