Discussion:
[omniORB] A question about stringified IOR in case of IPv6
Hung Ta Viet
2010-10-27 13:15:51 UTC
Permalink
Hi friends,

As you know, stringified IOR is a string that contains string in hexa decimal
e.g.
IOR:010000001300000049444c3a746573742f48656c6c6f3a312e30000001000000000000006c000000010102000f

00000031302e3132382e3234302e31323200004407000013000000ff6d79504f41002ccbc74c01001710000000000002000000000000000800000001

00000000545441010000001c00000001000000010001000100000001000105090101000100000009010100

In my knowledge, the hostname, which is the location of corba servant, can be in
IP address (e.g.172.169.2.3), is encoded in the above stringified IOR. When we
use IPv6 address, the format is e.g. 2001:DB8:0:0:8:800:200C:417A and it must be
put in '[' and ']' in the corbaloc:
corbaloc:iiop:[2001:DB8:0:0:8:800:200C:417A]:2809/NameService.

My question are:
1.. Are the square parentheses '[' and ']' also encoded and included in the
stringified IOR? or what?
2. We have some classes in which we can get the hostname of an IOR:
class IIOP {
public:

typedef GIOP::Version Version;

struct Address {
_CORBA_String_member host;
_CORBA_UShort port;

void operator>>=(cdrStream&) const;
void operator<<=(cdrStream&);
};

struct ProfileBody {
Version version;
Address address;
_CORBA_Unbounded_Sequence_Octet object_key;
IOP::MultipleComponentProfile components;

ProfileBody() : components(2) {}
};

Does the host of struct Address contain square parentheses?

Your support is always welcome.

Best regards,
Hung



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.omniorb-support.com/pipermail/omniorb-list/attachments/20101027/32a16f64/attachment.htm
Duncan Grisby
2010-10-27 19:37:34 UTC
Permalink
Post by Hung Ta Viet
As you know, stringified IOR is a string that contains string in hexa
decimal e.g.
Just for clarification, an IOR is an Interoperable Object Reference. It
the the way all object references in CORBA are transmitted. The
stringified IOR is just a hex string form of the same thing.
Post by Hung Ta Viet
1.. Are the square parentheses '[' and ']' also encoded and included
in the stringified IOR? or what?
No, the address in the IOR does not have the square brackets.
Post by Hung Ta Viet
class IIOP {
[...]
Post by Hung Ta Viet
Does the host of struct Address contain square parentheses?
No.

However, having said that, some CORBA implementations, for example some
versions of Weblogic, do incorrectly store the square brackets in IORs.
The latest svn snapshots of omniORB therefore ignore the square brackets
if they're there.

Cheers,

Duncan.
--
-- Duncan Grisby --
-- ***@grisby.org --
-- http://www.grisby.org --
Loading...