Skip to main content

Binding Unit Siganture File

7 replies [Last post]
mihailm
Offline
Joined: 2008-01-24
Points: 0

Hi all,

I'm trying to create the bumf.xml and bumf.sf files. I think I got the concept of creating the bumf.xml file, but the bumf.sf is a mystery for me. I read the Spec. a couple of times but it still is unclear to me how this file should look like. Any help will be much appreciated.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
jaya_h
Offline
Joined: 2005-07-11
Points: 0

Hi Mihailm,

We have updated the BDSigner tool in hdcookbook with new filenames for the BUMF (bumf.xml) and signed BUMF (bumf.sf).

Let us know if the BUMF signer works for you as expected..

Thanks,
Jaya

greg_bdj
Offline
Joined: 2008-04-08
Points: 0

hello,

first let me thank you for the great tools you have provided along with the book!

I have recently updated the project to use the latest from the hdcookbook project:
I have observed that if BDCertGenerator is called as described in the readme files and help, it will crash generating a null exception:
...>java -cp "..\build\security.jar;C:\Programmi\Java\jdk1.6.0_04\lib\tools.jar;..\resource\bcprov-jdk15-137.jar" net.java.bd.tools.security.BDCertGenerator -app 56789abc
Certification request stored in file
Submit this to your CA
java.lang.NullPointerException
at net.java.bd.tools.security.SecurityUtil.issueCert(SecurityUtil.java:7
89)
at net.java.bd.tools.security.SecurityUtil.generateCSRResponse(SecurityU
til.java:430)
at net.java.bd.tools.security.SecurityUtil.createAppCert(SecurityUtil.ja
va:383)
at net.java.bd.tools.security.SecurityUtil.createCerts(SecurityUtil.java
:353)
at net.java.bd.tools.security.BDCertGenerator.main(BDCertGenerator.java:
133)

looks like the correct way is to call instead with -root option. Is this correct?

I used the SVN tag version hdcookbook-27 (same observed on latest from the trunk).

If instead you call -root first, then calling with -app after that is ok (i.e. won t crash as -root generates some of the files required for -app, so it seems).

what should be the correct system calls:
step 1: BDCertGenerator -root (copy app.discroot.cert in CERTIFICATE)
step 2: BDCertGenerator -app (is it needed??)
step 3: BDSigner (if one wants to sign jar files)

Are the above steps correct?
what are the files needed by BDsigner from step 1 and/or 2?

Thanks!
Greg

jaya_h
Offline
Joined: 2005-07-11
Points: 0

Hi Greg,

The correct sequence is as below. Step1 generates root certificate, which can then be used to sign the application certificate.

step 1: BDCertGenerator -root (copy app.discroot.cert in CERTIFICATE)
step 2: BDCertGenerator -app (is it needed??) -- YES.
step 3: BDSigner (if one wants to sign jar files)

If you directly try to generate a application certificate without specifying the issuer of the certificate (i.e the root), the tool will fail.
We will have the tool generate an error message for this case instead of throwing NullPointerException.

Thanks,
Jaya

jaya_h
Offline
Joined: 2005-07-11
Points: 0

Hi Mihail,

The spec that I referred to specifies: .bumf and .busf as extensions. Looks like I'm referring to the older version of the spec.
I will soon update the BDSigner tool on hdcookbook if the spec has been revised and the new extensions are: .xml and .sf.

Thanks for checking out the BUMF signer tool.

Thanks,
Jaya

billf
Offline
Joined: 2004-02-13
Points: 0

Hi Mihailm,

Check out the SVN repository at hdcookbook.dev.java.net. I just did a grep for ".busf", and found this in tools/security/src/net/java/bd/tools/security/SecurityUtil.java:

/**
* This method signs the Binding Unit Manifest File according to the
* BD-J specification, Part: 3-2, section: 12.2.8.1 and
* 2.2.8.1.4 (verification).
* @throws java.lang.Exception
*/
public void signBUMF() throws Exception {
...
String sigFile = prefix + ".busf";

...
}

It's part of the signing tools described under tools/security. Jaya,
who wrote it, is out until Monday, but starting then she'll be available
for questions.

HTH,

Bill

mihailm
Offline
Joined: 2008-01-24
Points: 0

Hi Bill,

Thanks for the info! It really helped.
I've noticed some bugs ( well I think that they are bugs, but this might not be the case ) though.
The first thing is that the Binding Unit Manifest File ( bumf file ) should be named bumf.xml ( according to Spec section 5.7 ) and in the BDSigner file in the main() method actualy it is looking for a file with an extension of .bumf.

if (args[i].endsWith(".bumf")) {
builder = builder.bumf(args[i]);
isBUMF = true;
}
Please correct me if I'm wrong but from all I've read so far it seems to me that this BUMF file should be bumf.xml.
The other thing is that the Binding Unit Signature File should end on .sf and not ".busf". This is again mentioned in the same section of the Spec.
Otherwise the tool is working perfectly. I was able to sign my BUMF file and I will continue with the BUDA experiments.

Mihail Markov

Joe Rice

A note on this...

You're right, once the player moves the BUMF ad BUSF to the disc-
dependent directory as part of the process of preparing the update,
the files are named bumf.xml and bumf.sf (this was changed in the 2.1
spec from .bumf and .busf). However, the source files can be named
whatever you want. The source filenames are passed to the VFS Manager
when the update is requested and it takes care of copying and renaming
them.

That said, one should stick to 8.3 file names for all files written to
the BUDA, since some players use FAT16 formatted storage (eg SD cards)
which can't support longer names, so looking for a .xml extension by
default and writing a .sf extension probably should be the right
behavior.

Cheers,
Joe

On Mar 31, 2008, at 6:36 AM, bd-j-dev@mobileandembedded.org wrote:

> Hi Bill,
>
> Thanks for the info! It really helped.
> I've noticed some bugs ( well I think that they are bugs, but this
> might not be the case ) though.
> The first thing is that the Binding Unit Manifest File ( bumf file )
> should be named bumf.xml ( according to Spec section 5.7 ) and in
> the BDSigner file in the main() method actualy it is looking for a
> file with an extension of .bumf.
>
> if (args[i].endsWith(".bumf")) {
> builder = builder.bumf(args[i]);
> isBUMF = true;
> }
> Please correct me if I'm wrong but from all I've read so far it
> seems to me that this BUMF file should be bumf.xml.
> The other thing is that the Binding Unit Signature File should end
> on .sf and not ".busf". This is again mentioned in the same section
> of the Spec.
> Otherwise the tool is working perfectly. I was able to sign my BUMF
> file and I will continue with the BUDA experiments.
>
> Mihail Markov
> [Message sent by forum member 'mihailm' (mihailm)]
>
> http://forums.java.net/jive/thread.jspa?messageID=266778
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
> For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net
>

---------------------------------------------------------------------
To unsubscribe, e-mail: bd-j-dev-unsubscribe@hdcookbook.dev.java.net
For additional commands, e-mail: bd-j-dev-help@hdcookbook.dev.java.net