Skip to main content

 none
Basic Samples RRS feed

  • Question

  • Hi,

    For some time now I've been trying to get NetPeerTcp samples to run from the .Net 3 SDK.  Any code I've written including the basic IBroadcast sample provided always fail on the service host Open() method.  Always it raises an exception with the inner exception stating: {"The system detected an invalid pointer address in attempting to use a pointer argument in a call"}

     

    I'm not even sure where to begin trying to figure out how to resolve this problem.  Can you point me in the right direction?

     

    I'm on XP SP2 with the PNRPv2 update applied using Visual Studio 2005 behind a NAT firewall.

     

    Output from various commands are below:

    netsh p2p pnrp cl sh st *

    Scope  Id     Addr   State             Name
    -----  -----  -----  ----------------  -----
        3      4      1  Virtual           LinkLocal_{1E26DD7C-855C-4490-993A-C92CA0B6F8D0}

    Synchronize server:
    Use Server:             Disabled
    Use SSDP:               Not used
    Use Persisted cache:    Not used


    Scope  Id     Addr   State             Name
    -----  -----  -----  ----------------  -----
        1      0      1  Virtual           Global_

    Synchronize server:     pnrpv2.ipv6.microsoft.com;pnrpv21.ipv6.microsoft.com
    Use Server:             Not used
    Use SSDP:               Not used
    Use Persisted cache:    Not used

     

    ****************************************************

    netsh interface ipv6 show teredo

    Teredo Parameters
    ---------------------------------------------
    Type                    : client
    Server Name             : default
    Client Refresh Interval : default
    Client Port             : default
    State                   : qualified
    Type                    : teredo client
    Network                 : unmanaged
    NAT                     : restricted

     

    Help!

     

    Thanks very much.

     

    Regards,

    Roland Rodriguez

    Monday, April 23, 2007 11:24 AM

Answers

  • 0x80630203 is the PEER_E_NO_KEY_ACCESS HRESULT.  It is likely that the ACLs on the folder containing your RSA keys were changed from their installation defaults.  If you are comfortable changing these ACLs yourself then you can follow the instructions under the "RESOLUTION" section of Microsoft KB at http://support.microsoft.com/default.aspx/kb/817754 (if you create a restore point before you change them then you should be able to safely undo any changes).  This ought to solve the problem of PNRP not starting.

     

    Please post back with whether or not this helped.  It would be interesting to figure out why the ACLs changed from the installation defaults.

     

    Cheers,

    Eliot

    Thursday, April 26, 2007 1:29 AM

All replies

  • as a follow up, i'm getting a new message today saying that the pnrp service isn't started and indeed i can see that it's not.

     

    now i get the following output:

     

    net start pnrpsvc

    The Peer Name Resolution Protocol service is starting...
    The Peer Name Resolution Protocol service could not be started.

    A system error has occurred.

    System error 515 has occurred.

    The system cannot find message text for message number 0x203 in the message file for BASE.

     

    help please? 

     

    tia,

    Roland Rodriguez

    Wednesday, April 25, 2007 5:39 PM
  • Thanks for your interest in PNRP.

    We need some information to diagnose the problem.

    Could you please send the output of following command?

     sc query pnrpsvc

    Thanks,

    Pritam

     

    Wednesday, April 25, 2007 6:30 PM
  • thanks for your assistance, the output is as follows:


    SERVICE_NAME: pnrpsvc
            TYPE               : 20  WIN32_SHARE_PROCESS
            STATE              : 1  STOPPED
                                    (NOT_STOPPABLE,NOT_PAUSABLE,IGNORES_SHUTDOWN)
            WIN32_EXIT_CODE    : -2140995069        (0x80630203)
            SERVICE_EXIT_CODE  : 0  (0x0)
            CHECKPOINT         : 0x0
            WAIT_HINT          : 0x0

     

    attempting to start the pnrp service fails and the following error is logged in the event log:

    The description for Event ID ( 102 ) in Source ( PNRPSvc ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event: 0x80630203.

    Wednesday, April 25, 2007 10:38 PM
  • 0x80630203 is the PEER_E_NO_KEY_ACCESS HRESULT.  It is likely that the ACLs on the folder containing your RSA keys were changed from their installation defaults.  If you are comfortable changing these ACLs yourself then you can follow the instructions under the "RESOLUTION" section of Microsoft KB at http://support.microsoft.com/default.aspx/kb/817754 (if you create a restore point before you change them then you should be able to safely undo any changes).  This ought to solve the problem of PNRP not starting.

     

    Please post back with whether or not this helped.  It would be interesting to figure out why the ACLs changed from the installation defaults.

     

    Cheers,

    Eliot

    Thursday, April 26, 2007 1:29 AM
  • Fantastic Eliot,

     

    The Everyone group had one modify permission missing.  I added it and everything works now.  I really appreciate you getting me past this hump.  All the getting started demos and the test code I've written myself works now.  Can't thank you enough as this problem has been haunting me for months now!  Not sure how that ACL got modified or why it wasn't correct but I'm glad it's working now.

     

    Regards,

    Roland Rodriguez

    Thursday, April 26, 2007 7:13 PM
  • I'm glad to hear that you can get back on track.  I'm really sorry it took more than a month to get to the bottom of this issue.  Hopefully this forum post moves up in the search rankings for pnrp and "won't start"/"doesn't start".  We tracked down one source of this problem on Vista but haven't managed to track down what can cause it on XPSP2 so any information you could share about your setup would be helpful.

     

    Good luck and feel free to post any other questions you have,

    Eliot

    Thursday, April 26, 2007 9:04 PM
  • I am having the exact same problem. I have followed the instructions in the KB article to modify permissions on the ACL folders. I have removed and reinstalled PNRP. However, this problems persisits. I can share more of my setup details if you are interested.
    Friday, May 11, 2007 2:48 PM
  • smadhu,

     

    If you have followed the instructions in the KB (http://support.microsoft.com/kb/817754) then something may be modifying the permissions you set for  \Documents and Settings\UserName\Application Data\Microsoft\Crypto\RSA\<UserSID> (where UserSID is the SID of your user account) or \Documents and Settings\AllUsers\Application Data\Microsoft\Crypto\RSA\MachineKeys.  If you check these folders and they do not have the correct permissions after you set the permissions yourself then you will need to debug what is modifying the permissions.  I can provide you with instructions for doing so if this is the case (it involves using a utility program to watch for modifications to these folders and then seeing which process is modifying the ACLs on the folders).

    Monday, May 14, 2007 8:23 PM
  •  

    Thank you very much. 

     

    blahlblasd. you gave me a hint to update prnp to v2.0

     

    Eliot Flannery. you gave me the final solution.

     

    Thanks a lot for both of your help.

    Tuesday, May 15, 2007 7:26 AM
  •  

    I'm having the same error on my windows vista machine. Any instructions on how to fix it on vista ?

     

    JOhn Smyth

    Monday, September 3, 2007 1:34 PM
  • Hi Roland,

    Have you stopped the PNRP Service before getting this error?

    When you get that error, can you please run the following command from elevated window?

    "netstat -a".

    If it is ok, please send the output of that command.

    Thanks,

    Pritam

     

     

     

    Tuesday, September 4, 2007 9:00 PM
  • I've got the same problem, and granting access rights to the folder under "All Users" solved the problem.

    We have 3 test machines and 2 out of the 3 experienced this problem. These machines originally had Windows XP SP2, we have installed .NET Framework 3.5, XP SP3, and then .NET 3.5 SP1. Some anti-virus software were pre-installed and we have disabled them. Don't know who's in charge of the problem.

     

    Tuesday, September 9, 2008 5:37 AM