- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- realpath.patch, wu-ftp Installation
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-31-2007 11:21 AM
тАО07-31-2007 11:21 AM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-31-2007 02:27 PM
тАО07-31-2007 02:27 PM
Re: realpath.patch, wu-ftp Installation
reading the HP-UX forums than this Tru64
forum.
What's in the ".patch" file?
Does "patch - /patch path" make sense?
Have you tried using GNU "patch" instead of
the "patch" which comes with HP-UX?
http://www.gnu.org/software/patch/patch.html
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-01-2007 09:46 AM
тАО08-01-2007 09:46 AM
Re: realpath.patch, wu-ftp Installation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-01-2007 05:10 PM
тАО08-01-2007 05:10 PM
Re: realpath.patch, wu-ftp Installation
I can't see what's in your patch file, and I
can't see which directory you're in, or
what's in that directory, or exactly what
your actual "patch" command is, or which
"patch" program you're using. And I can't
read your mind at this distance. Should I
call the psychic, or would you like to do it?
Or, you could see if the people in the HP-UX
forum are better mind readers than I am.
(But I doubt that that will help.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-01-2007 06:06 PM
тАО08-01-2007 06:06 PM
Re: realpath.patch, wu-ftp Installation
patch(1) does say:
The message ``Hmm...'' indicates that there is unprocessed text in the patch file and that patch is attempting to intuit whether there is a patch in that text and, if so, what kind of patch it is.
You haven't exported UNIX95 have you??
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-02-2007 08:42 AM
тАО08-02-2007 08:42 AM
Re: realpath.patch, wu-ftp Installation
--- src/realpath.c.orig Mon Aug 4 11:20:19 2003
+++ src/realpath.c Mon Aug 4 11:23:22 2003
@@ -299,7 +299,7 @@
rootd = 0;
if (*wbuf) {
- if (strlen(resolved) + strlen(wbuf) + rootd + 1 > MAXPATHLEN) {
+ if (strlen(resolved) + strlen(wbuf) + !rootd + 1 > MAXPATHLEN) {
errno = ENAMETOOLONG;
goto err1;
}
the patch is in /tmp , from where i am trying to execute it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-02-2007 03:06 PM
тАО08-02-2007 03:06 PM
Solution> file
That's a start.
> the patch is in /tmp , from where i am
> trying to execute it.
Great. Now, if I knew what else was in that
directory, I might have a clue to what you're
doing. (I asked all those questions for
_your_ benefit, not for mine. The fewer you
answer, the less I can do.)
Around here:
dy# type patch
patch is hashed (/usr/bin/patch)
dy# patch < ../realpath.patch
Hmm... I can't seem to find a patch in there anywhere.
dy# type gpatch
gpatch is hashed (/usr/local/bin/gpatch)
dy# ls -l /usr/local/bin/gpatch
lrwxrwxrwx 1 root sys 5 Jul 30 15:59 /usr/local/bin/gpatch -> patch
dy# gpatch < ../realpath.patch
can't find file to patch at input line 8
Perhaps you should have used the -p or --strip option?
The text leading up to this was:
--------------------------
|A vulnerability has been found in the current versions of wu-ftpd, follow
|the links from http://www.wu-ftpd.org/ for details.
|
|Included below is a patch for CAN-2003-0466 to be applied to wu-ftpd 2.6.2.
|
|--- src/realpath.c.orig Mon Aug 4 11:20:19 2003
|+++ src/realpath.c Mon Aug 4 11:23:22 2003
--------------------------
File to patch: src/realpath.c
patching file src/realpath.c
Apparently, you have a "unified context diff"
patch file, which requires a "patch" program
which can understand those. The "patch"
supplied with HP-UX appears not to be such a
program, but GNU "patch" is. (Why it made me
specify the "File to patch" is a mystery to
me, but many things are.) It works about the
same for the other two recommended patches,
too.
http://www.wu-ftpd.org/
> Have you tried using GNU "patch" instead of
> the "patch" which comes with HP-UX?
>
> http://www.gnu.org/software/patch/patch.html
Perhaps I _am_ psychic.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-02-2007 06:04 PM
тАО08-02-2007 06:04 PM
Re: realpath.patch, wu-ftp Installation
You will have to attach the file since it gets corrupted if you don't retain the format.
When I changed it to look like this, it worked:
*** src/realpath.c Thu Aug 2 14:48:58 2007
--- src/realpath.c.new Thu Aug 2 14:50:12 2007
***************
*** 1,7 ****
rootd = 0;
if (*wbuf) {
! if (strlen(resolved) + strlen(wbuf) + rootd + 1 > MAXPATHLEN) {
errno = ENAMETOOLONG;
goto err1;
}
--- 1,7 ----
rootd = 0;
if (*wbuf) {
! if (strlen(resolved) + strlen(wbuf) + !rootd + 1 > MAXPATHLEN) {
errno = ENAMETOOLONG;
goto err1;
}
Using my GNU patch didn't like what I thought the original patch file should be:
patch: **** Only garbage was found in the patch input.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО08-02-2007 06:58 PM
тАО08-02-2007 06:58 PM
Re: realpath.patch, wu-ftp Installation
Use the source, Luke:
http://www.wu-ftpd.org/
ftp://ftp.wu-ftpd.org/pub/wu-ftpd/patches/apply_to_2.6.2/realpath.patch
ftp://ftp.wu-ftpd.org/pub/wu-ftpd/patches/apply_to_2.6.2/
The wu-ftpd.org server was dead for a while,
but it seems to be alive again, now.