"G. A person who is a legal resident of this state may bring an action in superior court to challenge any official or agency of this state or a county, city, town or other political subdivision of this state that adopts or implements a policy or practice that limits or restricts the enforcement of federal immigration laws to less than the full extent permitted by federal law." . . . . .