Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Rendezvous question

Rendezvous question
Thread Tools
Professional Poster
Join Date: Sep 2000
Location: San Francisco
Status: Offline
Reply With Quote
Jun 2, 2003, 02:00 PM
 
I'm having trouble getting my rendezvous enabled app to work. Here's the situation:

It works great at home over airport between my G4 and my iBook (both with 10.0.1.x IPs), but I can't seem to get it to work at work. The computers I am trying it on are on the same subnet and they seem to see each other as the rendezvous code is returning the names of the remote machines and it says it has resolved the addresses. The problem is that the addresses they resolve don't seem to be correct or the remote machines can't be found with the resolved adress or they won't respond. Is there something simple I might be missing here? I'm not quite sure how to get the resolved addresses to print out in a human readable format. I tried this:

Code:
NSData * address = [[[discoveredServices objectAtIndex:index] addresses] objectAtIndex:0]; NSLog(@"address=%@",[address description]);
but the address that it prints isn't an IP which is what I was expecting.

kman
     
Professional Poster
Join Date: Oct 2001
Location: London
Status: Offline
Reply With Quote
Jun 2, 2003, 05:14 PM
 
If you pass an instance of a class to NSLog - it is the equivalent of passing it [obj description]

so you only need to write NSLog(@"data: %@", theData)

Anyway - back to the point - the data you are passed is not an "address object" it is an NSData object that contains a C struct - specifically: sockaddr_in

see here for more info:

http://www.macdevcenter.com/pub/a/ma...oa.html?page=2
     
kman42  (op)
Professional Poster
Join Date: Sep 2000
Location: San Francisco
Status: Offline
Reply With Quote
Jun 2, 2003, 06:25 PM
 
I turned off the firewall on the remote machine and now it works great. Is there a specific port range that it is okay to use for your own app? I don't want to conflict with anything.

kman
     
Senior User
Join Date: Nov 2000
Status: Offline
Reply With Quote
Jun 3, 2003, 04:42 AM
 
Originally posted by kman42:
I turned off the firewall on the remote machine and now it works great. Is there a specific port range that it is okay to use for your own app? I don't want to conflict with anything.
If it's an app that you're intending to unleash on the world, you should probably get an assigned port from IANA. However, if it is a rendezvous only service, you could allow the OS to assign you a dynamic address and just advertise the port over Rendezvous and require no assigned port, but that approach could cause problems with machines with firewalls having no definate port to open up.

- proton
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 03:38 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2