语言

Menu
Sites
Language
CLI certified package considered invalid [33]

UPDATE: Issue solved, see end of the thread.

I've tried signing the command line packaged app for some time now, but so far without a success. When the package is re-packaged using IDE (as per suggestion), it works. However, to fully integrate the signing into development process, it needs to be doable via command line. 

  • Certificate: Created .p12 file using both IDE and command line tools. No difference in outcome.
  • Updated profiles.xml (following the IDE generated profiles.xml)
  • Building & signing: Using web-build and webtizen commands
  • Package contents seems same when comparing the outcome with both CLI and IDE-packaged versions. Only the hashes in XML file are changed, not the contents themselves.

The error that I'm getting: CERTIFICATE_INVALID [33]. I also tried putting the CLI -generated signature files into IDE -based WGT -package, but then error was: SIGNATURE_INVALID [22].

Therefore: Any hints where to look in a case of error: 33?

编辑者为: Juha Mustonen 28 11月, 2013

响应

8 回复
Juha Mustonen

Update: I tried removing the signature1.xml and author-signature.xml files from the package (to see whether I'm getting the old error). And the error still is CERTIFICATE_INVALID [33]?

Juha Mustonen

Another update:  Signed package can be now installed succesfully to device, but emulator still consideres the certificate invalid [33]? SDK 2.2 in use.

Juha Mustonen

Rootcause found: The problem was in emulator. For some reason, one particual emulator instance (all created from same image and using same SDK) doesn't like the package. 

Fix: Created a new emulator and it works.

Juha Mustonen

There is something fishy going on: Package can now be built and signed on command line, as well as installed to emulators. But when building is done in CI environment, with the same certificates and p12 files (we even put them to version control), the both emulators decline to install the application.

Can you share you insight about what is going on?

Juha Mustonen

Log output when trying to install WRT package to device:

D/AUL_AMD (  575): amd_key.c: _unregister_key_event(155) > ===key stack===
D/AUL_AMD (  575): amd_key.c: _unregister_key_event(160) > pid : 608
D/WRT_INSTALLER(16448): dlog_log_provider.cpp: Debug(62) > [SECURE_LOG] [wrt-installer.cpp:344] OnTerminate(): Wrt Shutdown now
D/WRT_INSTALLER(16448): dlog_log_provider.cpp: Debug(62) > [SECURE_LOG] [plugin_utils.cpp:73] unlockPluginInstallation(): Unlock for plugins installation.
E/WRT_INSTALLER(16448): dlog_log_provider.cpp: Error(104) > [SECURE_LOG] [plugin_utils.cpp:93] unlockPluginInstallation(): Lock file was not created!
D/WRT_INSTALLER(16448): dlog_log_provider.cpp: Debug(62) > [SECURE_LOG] [wrt-installer.cpp:1183] main(): App returned: 0
D/WRT_INSTALLER(16448): dlog_log_provider.cpp: Debug(62) > [SECURE_LOG] [wrt-installer.cpp:1185] main(): WrtInstaller returned: 32
D/WRT_INSTALLER(16448): dlog_log_provider.cpp: Debug(62) > [SECURE_LOG] [wrt-installer.cpp:95] ~WrtInstaller(): App Finished
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:674] RemoveListener(): Listener unregistered
D/DPL     (16448): dlog_log_provider.cpp: Pedantic(120) > [SECURE_LOG] [event_support.h:616] ~EventSupport(): Disabling events for EventSupport

 

Juha Mustonen

Finally solved the issue: The signed package is invalid when using java-1.6, whereas java-1.7 signed package is valid. 

Now this is something you may want to clearly document in Tizen SDK installation instructions.

Juha Mustonen

Also, one possibility is the existing application, signed with different key: https://developer.tizen.org/forums/sdk-ide/problem-creating-valid-certificate#comment-9698

AVSukhov

Hello,

Thanks for sharing information. It will be helpful.