So I'm not new to codesigning with Apple. I understand this is a novice part of app development, but I'm getting this error and I can't solve it. I understand that I create a private key through keychain access, use that private key to generate a certificate, use that certificate and an appID to generate a provisioning profile, and use an "App Store" profile to codesign for distribution. But I think I'm running into this error because of xcode 4.2. But this is what I've done to try and resolve this issue:
So after a long pain staking process I finally got xcode to code sign with out the warning. But before I tell you how I solved it, I'm going to tell you what I've done.
I cleared out all my public/private keys, cleared all certificates, uninstalled xcode 4.0.2, reinstalled xcode 4.2 (tried redoing certificates), uninstalled xcode 4.2, installed xcode 4.0.2 (tried redoing certificates), and after all that, still no luck.
Finally I deleted the WWDR certificate from my local machine and downloaded a new certificate from the provisioning portal, and YATZEE! After I redid the certificates and provisioning profile, it finally built without a warning!
So just so anyone has to go through this I've decided to post my answer. I hope I help someone...