I was also getting this error "You are not allowed to perform this operation. Please check with one of your Team Admins, or, if you need further assistance, please contact Apple Developer Program Support". My developer provisioning was not working so I could not even test my apps on device.
Here's what worked for me:
- Go on the iOS Provisioning Portal > Certificates > Development. There is probably a Certificate there which you no longer have the key pair for in Keychain. Revoke it.
- Delete the relevant profiles from the Xcode organizer. Quit Xcode.
- Go to ~Library/Developer/Xcode and delete connect1.apple.com **.db (maybe not necessary, but won't hurt).
- Go to ~Library/Caches/com.apple.dt.Xcode and delete the Cache* files.
Now, Xcode is supposed to automatically create a new developer cert, but that seems to be broken right now. So, don't try to use it. Instead:
- Go back to the iOS Provisioning Portal.
- Make sure that your development certificate is revoked (so you don't have one).
- Now Create a new one, and use the manual process which involves using keychain (we're back in 2009 here). Download the cert.
- Go back to Xcode > Organizer. Plug in your device. Click on "Provisioning Profiles" under your device name. Delete all certificates currently on the device.
- Click on the device name. Click "Add to Portal" at the bottom. Go through that process.
- Go back to Library > Provisioning Profiles (at the top left). If you have an extra Team Provisioning Profile that is invalid, delete it.
Now you should have a working system.