Before any Viper or Raptor can fire weapons, permission must be given for members of the fighter group to do so. The request or command is called "weapons free."
The lead pilot of a Combat Air Patrol, or group of Alert Fighters (typically the CAG) can give a "weapons free" order when facing a known enemy.
Any member of a fighter group can request weapons-free authorization from the lead pilot, usually as part of training missions (Home, Part I) or to verify their fighter's gun operation (Epiphanies).
In special cases, the lead pilot may defer weapons-free authorization to the battlestar commander. Lead pilot Kat defers weapons-free authorization for her fighter group to Galactica Actual after the battlestar launches her fighters against sister battlestar Pegasus and her Vipers, realizing that ordering fire against fellow Colonials required Commander Adama's authorization (Resurrection Ship, Part I).