Merge "Expose hidden API to check whether a given package is state protected" into pi-dev