Operating System - HP-UX
1748143 Members
3663 Online
108758 Solutions
New Discussion юеВ

Error code2: Access violation when using "put" with tftp

 
Jason Tedford
New Member

Error code2: Access violation when using "put" with tftp

I'm trying to "put" a file in the tftpdir using tftp. The directory is wide open but the file does not exist as a default. When I attemp this I get the error "Error code 2: Access violation"

However, when I pre-create and open up the file at the destination using:
> touch junk.filename
> chmod 777 junk.filename

I can successfully write or in this case overwrite the file. Is there somewhere in the inetd.conf file or elsewhere where I can allow "put" to create a file in the tftpdir?

I'm using HP/UX 11.11

Regards.
Jason
2 REPLIES 2
Steven Schweda
Honored Contributor

Re: Error code2: Access violation when using "put" with tftp

I don't know, but I doubt it. It's a
general property of TFTP servers to allow a
PUT only to an existing file. With the basic
security limitations of TFTP, this limitation
is supposed to help prevent people from
filling your file system with junk (which
would otherwise be even easier).

If you can allow it, you might be wiser not
to.

"man tftpd"?

[...] Furthermore, tftp
clients can only read files in that directory if they are
readable by the pseudo-user tftp, and tftp clients can only
write files in that directory if they exist and are writable by
the pseudo-user tftp.
Peter Godron
Honored Contributor

Re: Error code2: Access violation when using "put" with tftp

Hi,
and welcome to the forums !
OldSchool's answer in
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=999726
"If the server is to receive a file, it must already exist and be writeable by the user tftp."

Confirmed in "Common tftp problems"
http://docs.hp.com/en/5991-6548/ch03s05.html


Please also read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#33 on how to reward any useful answers given to your questions.