No, under the law, a Law enforcement agency can pay an informant for information, but they cannot pay a criminal to do another crime that otherwise he would not be involved in. That in-and-of-iteself is another crime. First of all it is the felony of conspiracy without even involving the criminal they are going to induce to commit the crime.
I am certain the FBI has done this in past sting cases.
Sorry, it was not a crime to get into that iPhone. Two issues come into play here;
1) the owner of the phone is dead and no longer has an expectation of privacy
2) the FBI had a warrant (I believe it is still sealed) to search the home of the shooter and it is reasonable to assume that the warrant was also for the contents of that phone.
SCOTUS In 2014, by a 9-0 vote, the justices said smart phones and other electronic devices were not in the same category as wallets, briefcases, and vehicles — all currently subject to limited initial examination by law enforcement. Generally such searches are permitted if there is “probable cause” that a crime has been committed, to ensure officers’ safety and prevent destruction of evidence.