-e option not present

Bug #566377 reported by Joshua
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
netcat (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: netcat

I run backups like this (yeah I know not secure):

'nc -l -p 1000 -e dump.sh' & ssh backupserver nc workstation 1000 \| tar -xf -

contents of dump.sh:

#!/bin/sh
tar -cf - *

Well the new version of netcat has no equivalent of -e so this breaks and I can't easily fix it.

ProblemType: Bug
DistroRelease: Ubuntu 10.04
Package: netcat 1.10-38
ProcVersionSignature: Ubuntu 2.6.32-21.31-generic 2.6.32.11+drm33.2
Uname: Linux 2.6.32-21-generic x86_64
Architecture: amd64
Date: Sun Apr 18 19:15:43 2010
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: netcat

Revision history for this message
Joshua (joshudson) wrote :
Revision history for this message
Joshua (joshudson) wrote :

I've got enough other uses that trying to fix this one isn't going to cut it.

Revision history for this message
Emanuele Cammarata (scinziatu) wrote :

The same happens on i386.
Moreover, -c is missing too, and -l -p 1000 doesn't work anymore, it now needs to be -l 1000.
This things break many old shell scripts

Revision history for this message
Eri Ramos Bastos (bastos-eri) wrote :

I think you may be looking at the wrong version of Netcat:

$ which nc
/bin/nc
$ ls -ld /bin/nc
lrwxrwxrwx 1 root root 20 2010-05-17 21:34 /bin/nc -> /etc/alternatives/nc
$ ls -ld /etc/alternatives/nc
lrwxrwxrwx 1 root root 15 2010-05-17 21:34 /etc/alternatives/nc -> /bin/nc.openbsd

But you are actually looking for /bin/nc.traditional :

$ /bin/nc.openbsd -l -p 9999 -e /bin/bash
/bin/nc.openbsd: invalid option -- 'e'
usage: nc [-46DdhklnrStUuvzC] [-i interval] [-P proxy_username] [-p source_port]
   [-s source_ip_address] [-T ToS] [-w timeout] [-X proxy_protocol]
   [-x proxy_address[:port]] [hostname] [port[s]]
$ /bin/nc.traditional -l -p 9999 -e /bin/bash
^C
$

You can fix that by:

$ sudo rm /etc/alternatives/nc && sudo ln -s /bin/nc.traditional /etc/alternatives/nc

Changed in netcat (Ubuntu):
status: New → Invalid
Revision history for this message
Bump (bump55) wrote :

So ubuntu now uses nc.openbsd as nc and the other nc.traditional has to be installed. It's called nc-traditional.

Revision history for this message
Joshua (joshudson) wrote : Re: [Bug 566377] Re: -e option not present

I pitched ubuntu into the garbage more than two years ago. Go away.

On 7/22/12, Bump <email address hidden> wrote:
> So ubuntu now uses nc.openbsd as nc and the other nc.traditional has to
> be installed. It's called nc-traditional.
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/566377
>
> Title:
> -e option not present
>
> Status in “netcat” package in Ubuntu:
> Invalid
>
> Bug description:
> Binary package hint: netcat
>
> I run backups like this (yeah I know not secure):
>
> 'nc -l -p 1000 -e dump.sh' & ssh backupserver nc workstation 1000 \|
> tar -xf -
>
> contents of dump.sh:
>
> #!/bin/sh
> tar -cf - *
>
> Well the new version of netcat has no equivalent of -e so this breaks
> and I can't easily fix it.
>
> ProblemType: Bug
> DistroRelease: Ubuntu 10.04
> Package: netcat 1.10-38
> ProcVersionSignature: Ubuntu 2.6.32-21.31-generic 2.6.32.11+drm33.2
> Uname: Linux 2.6.32-21-generic x86_64
> Architecture: amd64
> Date: Sun Apr 18 19:15:43 2010
> PackageArchitecture: all
> ProcEnviron:
> LANGUAGE=
> PATH=(custom, user)
> LANG=en_US.UTF-8
> SHELL=/bin/bash
> SourcePackage: netcat
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/ubuntu/+source/netcat/+bug/566377/+subscriptions
>

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.