Validate group and project names in forms.

Change-Id: Ia105eb022d59db9e03f9bd3b1ea2d6a1aae6ac22