To use voice commands even when your phone is locked, authenticate with Moto Voice:
While training the phone to recognize your voice prevents most other people from launching Moto Voice on your phone, this doesn't completely exclude other voices with a similar pitch and cadence.