how to resolve code signing warning while making archive file to test on ios device? - codesign

i got warning like Unable to validate your application. - (null)warning: Application failed codesign verification. The signature was invalid.
This bundle is invalid. The application-identifier entitlement is not formatted correctly; it should contain your 10-character App ID Seed, followed by a dot, followed by your bundle identifier:

This means that your previous provisioning profile/s has been expired. Go to Developers portal and revoke your certificate and generate new provisioning., download and install them and set xcode setting to new one.
second option: set the "valid provisioning" in "code signing" options in "Build settings" to none.

Related

Uiautomatorviewer Error while obtaining UI hierarchy XML file: com.android.ddmlib.SyncException: Remote object doesn't exist

i can launch Uiautomatorviewer sucessfully, inspect any page/app at personal profile.
Once phone at work profile/launching any app installed under work profile then Uiautomatorviewer throws error:
Error while obtaining UI hierarchy XML file: com.android.ddmlib.SyncException: Remote object doesn't exist!
i am not sure why it behave like this suddenly, it used to work regardless personal / work profile last week.
i don't remember i change any configuration...
please help to give me clues why? i have followed many previous post suggestion to restart adb server, kill appium server, restart phone/laptop, disable enable developer options...etc. none works....
I tried to inspect personal profile now, the same error occurred:
Error while obtaining UI hierarchy XML file: com.android.ddmlib.SyncException: Remote object doesn't exist!
updated: i used appium studio inspector and it works. I still not sure what happened to adb or uiautomator via command line? how do i debug it?
found an answer
com.android.ddmlib.SyncException: Is a directory
try doing adb shell rm -rf /data/local/tmp and rebooting the phone first. it's ok if you get rm: /data/local/tmp: Permission denied. ignore it - it's for the tmp folder itself after its content was already removed (that's what you need anyway)

Running tSQLt project from sources fails on the due to the Public Token mismatch

I'm trying to do some improvements for tSQLt framework and I'm mostly finish, but can't do that as few tests related to the certificate I wasn't touching are still failing:
[exec] |18|[InstallExternalAccessKeyTests].[test creates correct certificate in master] | 120|Failure|
[exec] |19|[InstallExternalAccessKeyTests].[test tSQLt can be set to EXTERNAL ACCESS after InstallExternalAccessKey executed] | 333|Failure|
[exec] |20|[InstallExternalAccessKeyTests].[test tSQLtExternalAccessKey install data is signed with same key as tSQLt.clr] | 10|Failure|
The failing error is:
Expected: %publickeytoken=8c9a92de0f9c7794,%
Actual: tsqltclr, version=1.0.7216.13228, culture=neutral, publickeytoken=8d3f4bf59e4c22fd, processorarchitecture=msil
I'll try to describe my installation process.
I installed this framework sources by using following guideline. However I couldn't start the project after that as it was failing with the following errors and the whole problem solving was done in that SO post:
[exec]
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(2482,5):
error MSB3325: Cannot import the following key file:
tSQLtOfficialSigningKey.pfx. The key file may be password protected.
To correct this, try to import the certificate again or manually
install the certificate to the Strong Name CSP with the following key
container name: VS_KEY_C20B79DE0583A5C1
[E:\Source\tSQLt\tSQLtCLR\tSQLtCLR\tSQLtCLR.csproj] [exec]
C:\Windows\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(2482,5):
error MSB3321: Importing key file "tSQLtOfficialSigningKey.pfx" was
canceled. [E:\Source\tSQLt\tSQLtCLR\tSQLtCLR\tSQLtCLR.csproj]
to pass this issue, I've created new keys for every project with no password:
I see that it created snk file, not as original pfx. After that I've tried to run the build again and it failed with the errors I mentioned above.
As stated here
The following error may occur when building projects for Microsoft Visual Studio 2008 - 2015.
Error: Cannot import the following key file: mykey.pfx. The key file may be password protected.
Cannot import the following key file: mykey.pfx. The key file may be
password protected. To correct this, try to import the certificate
again or manually install the certificate to the Strong Name CSP with
the following key container name: VS_KEY_C1D3ACB8FBF1AGK4
SOLUTION 1:
Click Start > All Programs > Microsoft Visual Studio >Visual Studio
Tools > Visual Studio Command Prompt. Type the following command
sn -i "c:\Pathtofile\.pfx" VS_KEY_C1D3ACB8FBF1AGK4
Note: The sn.exe with the -i parameter, installs a key pair from into a key container named.Re-import the PFX file into Visual Studio.
SOLUTION 2:
Open Project Properties.
Click on the Signing section.
Where it says ‘Choose a strong name key file:’, re-select the current value from the drop-down box
Visual Studio will now prompt you for the password. Enter it. You might get another error message:
”An attempt was made to reference a token that does not exist” > You can simply ignore this message.
Click the ‘Change Password” button
Enter the original password in all three boxes and click OK. If you’d like to change
your password (or if your old password doesn’t meet complexity requirements), you can do so now.
Repeat for each key file in your project.
Save your project and do a rebuild.
SOLUTION 3:
Get a copy of openssl for windows at slproweb.com or use a Linux box as they all pretty much have it.
Run the following to export to a key file
openssl pkcs12 -in certfile.pfx -out backupcertfile.key
openssl pkcs12 -export -out certfiletosignwith.pfx -keysig -in backupcertfile.key
Then in the project properties you can use the PFX file
SOLUTION 4:
The final solution for this issue is to give up on Visual Studio for signing purpose and use Signtool instead.
Updated Answer
It seems that your TFS Build Service account has no required permission to access the signingKey.pfx on build agent machine.
Make sure you have this file on build agent machine first.
Then follow below steps:
Log on the build agent as your local build service account (Better have Administrator permission)
Open a visual studio command prompt and navigate to the directory
the key is stored in
Type command sn –i signingKey.pfx VS_KEY_EFCA4C5B6DFD4B4F(Ensure that you use the key name appearing in the error message)
When prompted for a password type the password for the pfx file
Then rebuild it
Note: If you are not running Visual Studio as an Administrator try doing that as well.
More details you can reference the answer from Brandon Manchester Cannot import the keyfile 'blah.pfx' - error 'The keyfile may be password protected'

Invalid password? when sending iOS debug build on new machine

We are having the following problems :
An existing CN1 project is working fine on machine A (Windows) and we can send iOS builds to the server.
Now we also want to work on the project on machine B (MacOS) but we cannot get this to work.
We keep getting a build error on the server.
While we use the same certificates, provisioning profiles and login settings.
The error log shows a possible problem with a password (see below).
We put an echo statement in build.xml to echo the password and it is correct.
So what can be the problem?
Below is the last part of the error log:
[!] Please close any current Xcode sessions and use Maximus.xcworkspace for this project from now on.
Sending stats
Pod installation complete! There are 0 dependencies from the Podfile and 0 total pods installed.
[!] The Podfile does not contain any dependencies.
Process return code is 0
openssl pkcs12 -in [password redacted] -out cert.crt.pem -password pass:passwordHidden -passout pass:password
Process return code is 0
Mac verify error: invalid password?
Process return code is 1
The password for the certificate in codenameone_settings.properties was broken somehow in the other machine. This has nothing to do with your account.
Compare both codenameone_settings.properties files also make sure the password isn't defined globally in which case you might need to redefine it. To be clear I'm referring to one or both of the ios.certificatePassword values in the settings.

Codename one uwp sumbission fail

I'm trying to submit an app to the windows store, but submission failed with the following error:
Invalid package publisher name: CN=Steve (expected: CN= ... )
, which make me realized that the AppxBundleManifest generated from server contains this line
<Identity Name="42415WefeelPharm.HttpRequestor" Publisher="CN=Steve" Version="1.0.1.0"/>
I've confirmed that the correct package publisher id is used to generate the certificate. Please advice on how to proceed. Any help is appreciated.
Edit:
The setting UI for Windows
Edit edit:
I used Windows 10, jdk1.8.0_131, Eclipse 4.7 for the build...
Go to your account settings -> https://dev.windows.com/en-us/Account/Management
In the page you will see your "Windows publisher ID" copy the value "CN=xXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX60"
Go to VS, open the Package.appxmanifest, go to the line:
Change "CN=Steve" to the value you copied, "CN=xXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXX60", and that's it. Compile it and try again

Getting started with gcutil and Compute Engine: Error: The resource 'projects/<project-id>' was not found

I am attempting to get up and running with Google Compute Engine and am following the getting started/hello world tutorial. After installing gcutil (running OSx) and Authenticating to Google Compute Engine the instruction is to pass the following command
$ gcutil getproject --project=<project-id> --cache_flag_values
However the following error message is returned
Error: The resource 'projects/<project-id>' was not found
Where project-id is the id of the project authenticated earlier. If I then try to execute any of the following commands in the tutorial (but including the project-id because cashing the value failed) e.g.
$ gcutil addfirewall http2 --project=<project-id> --description="Incoming http allowed." --allowed="tcp:http"
The same error gets returned.
I am working in the $HOME directory (the same directory that contains the gcutil-1.8.0 folder).
Could someone please tell me why I'm getting the projects not found error, and if possible how to overcome it?
Visit your project's "Compute Engine" page once, then run the command again:
$ gcutil getproject --project=<project-id> --cache_flag_values
for me. it works.
You must first enable billing in order to use Compute Engine.
https://console.developers.google.com/billing
Often you'll see this error when there is an authentication/authorization failure.
Make sure you ensure that the user account gcutil is authorized as matches a user account listed in the teams section of the (Cloud Console)[https://cloud.google.com/console]. You can find that under the gear icon in the upper right corner.
To confirm which account is being used by gcutil, run the following command:
$ gcutil auth --confirm_email --just_check_auth
INFO: Authorization succeeded for user xxx#xxx.com
If you find that you are authorized under the wrong account (multiple personas in chrome, for example) you can reauthorize gcutil with:
$ gcutil auth
Make sure that you follow this link in the right browser tab/context.
You can Used Two Steps:
Step 1: You will enable billing in order to use Compute Engine.
Step 2: And visit your project's Compute Engine page once, then run the command again.
it works Fine for me.

Resources