[jcifs] No Access Exception Question

Michael B. Allen miallen at eskimo.com
Wed Jul 10 05:48:52 EST 2002


On Tue, 9 Jul 2002 11:22:45 -0700
"Yibo Dong" <ydong at mail.arc.nasa.gov> wrote:

> 
> Hi, Mike,
> 
> Thanks for the quick response.
> 
> I have tried all the possible combinations of createnp and client
> calls based on the instructions on
> http://jcifs.samba.org/src/docs/pipes.html
> but still got rather consistent Access Denied errors, albeit at slight
> different locations each time in
> Jcifs.smb.SmbTransport.sendTransaction(SmbTransport.java) call. Please see
> the attached for all the test
> details.
> 
> My suspicion is that my configuration/setup for running those tests is
> the culprit. But where?

I  just  went through the CallNamedPipe example and it worked. You know you
will  need  to  supply appropriate authentication creadentials. It's pretty
standard  for  GUEST  to  be  disabled  these  days. If you run the example
without  them  you  indeed  get  AccessDenied (natrually). When you run the
callnp.exe example it works because it uses your creadentials from the LSA.
Try: 

  java CreateNamedPipe smb://ydong:mypass@host/IPC$/pipe/foo input output

Or use -Djcifs.properties=jcifs.prp and make a jcifs.prp with
username=ydong, password=mypass, ...etc.

If this is not your problem then there might be a Win2K specific issue. Are
you using a Laptop without an ethernet cable attached?

> 
> Any insights will be greatly appreciated.
> 
> -Yibo
> 
> P.S. I wonder if /P 0x5 you mentioned should have been /P 0x6?

Right, /P 0x6.

> 
> 
> -----Original Message-----
> From: Michael B. Allen [mailto:miallen at eskimo.com]
> Sent: Monday, July 08, 2002 11:22 AM
> To: Yibo Dong
> Cc: jcifs at samba.org
> Subject: Re: [jcifs] No Access Exception Question
> 
> 
> On Mon, 8 Jul 2002 10:01:53 -0700
> "Yibo Dong" <ydong at mail.arc.nasa.gov> wrote:
> 
> >
> > Hi,
> >
> > I have downloaded your jcifs package and are using the following pair in
> > a Windows 2000 environment (machine name: ydong, domain name: not used,
> > group name: CDS) to test:
> >
> > createnp \\.\pipe\name
> >
> > CallNamedPipe smb://ydong/IPC$/PIPE/name c:\JCIFSTest\pipes\inFile.txt
> > c:\JCIFSTest\pipes\outFile.txt
> >
> > The call "out.write( b, 0, n )" in CalledNamedPipe.java results in the
> > following access exception:
> >
> > jcifs.smb.SmbAuthException: Access denied 	at
> > jcifs.smb.SmbTransport.sendTransaction(SmbTransport.java:626) 	at
> > jcifs.smb.SmbSession.sendTransaction(SmbSession.java:123) 	at
> > jcifs.smb.SmbTree.sendTransaction(SmbTree.java:65) 	at
> > jcifs.smb.SmbFile.sendTransaction(SmbFile.java:456) 	at
> >
> jcifs.smb.TransactNamedPipeOutputStream.write(TransactNamedPipeOutputStream.
> > java:62) 	at CallNamedPipe.main(CallNamedPipe.java:44) Exception in thread
> > "main"
> 
> With  the  CallNamedPipe  example  you  have  to  use the /P 0x5 flags with
> creatnp. That might help. See this page for complete instructions on how to
> run those examples:
> 
>   http://jcifs.samba.org/src/docs/pipes.html
> 
> Also,  just  a  note, the available() method of the InputStream returned by
> SmbNamedPipe.getNamedPipeInputStream  is  not  implemented.  This  might be
> necessary for certain types of I/O. It is very high on my todo list though.
> 
> Mike
> 
> --
> http://www.eskimo.com/~miallen/c/jus.c
> 


-- 
http://www.eskimo.com/~miallen/c/jus.c





More information about the jcifs mailing list