This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 158256 - BD-J: Checkers for the "Application ID" and "Organization ID" should be added
Summary: BD-J: Checkers for the "Application ID" and "Organization ID" should be added
Status: RESOLVED FIXED
Alias: None
Product: javame
Classification: Unclassified
Component: CDC pack (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Denis Anisimov
URL:
Keywords:
Depends on:
Blocks: 162137
  Show dependency tree
 
Reported: 2009-02-10 08:47 UTC by martin_sladecek
Modified: 2009-09-18 11:33 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description martin_sladecek 2009-02-10 08:47:44 UTC
java.lang.NumberFormatException occurs during building when non numeric symbols present in the "Application ID" or
"Organization ID".
Comment 1 Petr Suchomel 2009-04-01 13:39:55 UTC
Update appropriate task to check for number correctness, otherwise throws BuildException with appropriate message 
Comment 2 Denis Anisimov 2009-04-02 15:44:27 UTC
Is it true that both "Application ID" and 
"Organization ID" should be only numeric ?
In this case we need at least deny enter non-numeric characters into the customizer fields.

Could you please provide stack trace of the mentioned exception.
Comment 3 Petr Suchomel 2009-04-03 13:48:41 UTC
I wonder, where the exception comes from. The system handles the number as a string (because it can be hexadecimal one),
and task imprints the field as string as well: <applicationId>0x" + appId + "</applicationId>"
Comment 4 Petr Suchomel 2009-04-03 13:49:15 UTC
See BdjBuildBdjo.java Ant task
Comment 5 bukh 2009-04-03 14:04:25 UTC
According "System Description Blu-ray Disc Read-Only Format Part 3 Audio Visual Basic Specifications Version 2.3 DRAFT3
March 2009":

There are two Organization ID: "Disc Organization ID" and "xlet_organization_id"
"Disc Organization ID" is part of the "CERTIFICATE/id.bdmv", And has next format: 32 bit, uimsbf.
"xlet_organization_id" is part of the BD-J Object, And has next format: 32 bit, uimsbf.

Section 5.10:
 "Disc_Organization_ID: This field contains the organization id of the disc (“Disc Organization ID”).
The value identifies the owner of the content on the disc. This value is used to construct Virtual
Package binding unit for the disc."
 
Section 10.2.5.3:
 "xlet_organization_id: The organization_id .... This value identifies the organization responsible for the Xlet.
Note that this value may differ from that of Disc_Organization_ID...."

According Section 10.2.5.2:
"application_identifier() {
xlet_organization_id 32 uimsbf
application_id 16 uimsbf
}" we may say that "Application ID" and "Organization ID" are the application_identifier in the Netbeans. Finally
according the "Section 14.5: Text encoding of application identifiers" - xlet organization id should be 32 bit unsigned
integer, application id should be 16 bit unsigned integer.

"DVB-GEM[4] defines the application_id values as follows
Table 14-4 – (Informative) Application_id values
Application_id values  Use
0x0000…0x3fff          Application_ids for unsigned applications
0x4000…0x7fff          Application_ids for signed applications
0x8000…0xfffd          Reserved for future use (by DVB)
0xfffe                 Special wildcard value for signed applications of an organisation
0xffff                 Special wildcard value for all applications of an organization"
Comment 6 Petr Suchomel 2009-04-03 14:19:31 UTC
Could be checked only in Ant tasks, customizes do not allow checking at the moment
Comment 7 Denis Anisimov 2009-04-04 13:05:15 UTC
I have added validators for JTextFields in customizer.
It seems the change is safe. I havn't noticed any problems.
It will prevent user from setting non-numeric values.

I can't check the place inside ant task where NPE occurs as originally mentioned 
in description because there is no stacktrace.

changeset:   125133:6b798441a32e
user:        Denis Anisimov <ads@netbeans.org>
date:        Sat Apr 04 16:02:15 2009 +0400
summary:     Fix for #158256 - BD-J: Checkers for the "Application ID" and "Organization ID" should be added
Comment 8 Quality Engineering 2009-04-09 19:28:02 UTC
Integrated into 'main-golden', will be available in build *200904091401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/6b798441a32e
User: Denis Anisimov <ads@netbeans.org>
Log: Fix for #158256 - BD-J: Checkers for the "Application ID" and "Organization ID" should be added