Skip to content
Newer
Older
100644 165 lines (120 sloc) 4.88 KB
6c16212 @cklein Clean checkout
cklein authored Feb 21, 2011
1 #
2 # Makefile for dsniff
3 #
4 # Dug Song <dugsong@monkey.org>
5 #
6 # $Id: Makefile.in,v 1.42 2001/03/15 08:34:42 dugsong Exp $
7
8 srcdir = @srcdir@
9 VPATH = @srcdir@
10
11 install_prefix =
12 prefix = @prefix@
13 exec_prefix = @exec_prefix@
14 libdir = @libdir@
15 sbindir = @sbindir@
16 mandir = @mandir@
17
18 CC = @CC@
19 CFLAGS = @CFLAGS@ -DDSNIFF_LIBDIR=\"$(libdir)/\"
20 LDFLAGS = @LDFLAGS@
21
22 PCAPINC = @PCAPINC@
23 PCAPLIB = @PCAPLIB@
24
25 LNETINC = @LNETINC@
26 LNETLIB = @LNETLIB@
27
28 NIDSINC = @NIDSINC@
29 NIDSLIB = @NIDSLIB@
30
31 DBINC = @DBINC@
32 DBLIB = @DBLIB@
33
34 SSLINC = @SSLINC@
35 SSLLIB = @SSLLIB@
36
37 X11INC = @X_CFLAGS@
38 X11LIB = @X_LIBS@ @X_PRE_LIBS@ -lXmu -lX11 @X_EXTRA_LIBS@
39
40 INCS = -I. $(NIDSINC) $(PCAPINC) $(LNETINC) $(DBINC) $(SSLINC) $(X11INC) \
41 -I$(srcdir)/missing
42 LIBS = @LIBS@ -L$(srcdir) -lmissing
43
44 INSTALL = @INSTALL@
45 INSTALL_PROGRAM = @INSTALL_PROGRAM@
46 INSTALL_DATA = @INSTALL_DATA@
47
48 RANLIB = @RANLIB@
49
50 HDRS = asn1.h base64.h buf.h decode.h hex.h magic.h options.h \
51 pathnames.h pcaputil.h record.h rpc.h tcp_raw.h trigger.h \
52 version.h vroot.h
53
54 SRCS = asn1.c base64.c buf.c hex.c magic.c mount.c pcaputil.c rpc.c \
55 tcp_raw.c trigger.c record.c dsniff.c decode.c decode_aim.c \
56 decode_citrix.c decode_cvs.c decode_ftp.c decode_hex.c \
57 decode_http.c decode_icq.c decode_imap.c decode_irc.c \
58 decode_ldap.c decode_mmxp.c decode_mountd.c decode_napster.c \
59 decode_nntp.c decode_oracle.c decode_ospf.c decode_pcanywhere.c \
60 decode_pop.c decode_portmap.c decode_postgresql.c decode_pptp.c \
61 decode_rip.c decode_rlogin.c decode_smb.c decode_smtp.c \
62 decode_sniffer.c decode_snmp.c decode_socks.c decode_tds.c \
63 decode_telnet.c decode_vrrp.c decode_yp.c decode_x11.c
64
65 GEN = mount.h mount.c nfs_prot.h nfs_prot.c
66
67 OBJS = $(SRCS:.c=.o)
68
69 LIBOBJS = dummy.o @LIBOBJS@
70
71 PROGS = arpspoof dnsspoof dsniff filesnarf macof mailsnarf msgsnarf \
72 sshmitm sshow tcpkill tcpnice @TCPHIJACK@ urlsnarf webmitm @WEBSPY@
73
74 CONFIGS = dsniff.magic dsniff.services dnsspoof.hosts
75
76 .c.o:
77 $(CC) $(CFLAGS) $(INCS) -c $(srcdir)/$*.c
78
79 all: libmissing.a $(PROGS)
80
81 mount.c: mount.x
82 rpcgen -h mount.x -o mount.h
83 rpcgen -c mount.x -o mount.c
84
85 nfs_prot.c: nfs_prot.x
86 rpcgen -h nfs_prot.x -o nfs_prot.h
87 rpcgen -c nfs_prot.x -o nfs_prot.c
88
89 $(LIBOBJS):
90 $(CC) $(CFLAGS) $(INCS) -c $(srcdir)/missing/$*.c
91
92 libmissing.a: $(LIBOBJS)
93 ar -cr $@ $(LIBOBJS)
94 $(RANLIB) $@
95
96 dsniff: $(HDRS) $(SRCS) $(OBJS)
97 $(CC) $(LDFLAGS) -o $@ $(OBJS) $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB) $(DBLIB) $(SSLLIB)
98
99 arpspoof: arpspoof.o arp.o
100 $(CC) $(LDFLAGS) -o $@ arpspoof.o arp.o $(LIBS) $(PCAPLIB) $(LNETLIB)
101
102 dnsspoof: dnsspoof.o pcaputil.o
103 $(CC) $(LDFLAGS) -o $@ dnsspoof.o pcaputil.o $(LIBS) $(PCAPLIB) $(LNETLIB)
104
105 filesnarf: nfs_prot.o filesnarf.o pcaputil.o rpc.o
106 $(CC) $(LDFLAGS) -o $@ filesnarf.o nfs_prot.o pcaputil.o rpc.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB)
107
108 macof: macof.o
109 $(CC) $(LDFLAGS) -o $@ macof.o $(LIBS) $(PCAPLIB) $(LNETLIB)
110
111 mailsnarf: mailsnarf.o buf.o pcaputil.o
112 $(CC) $(LDFLAGS) -o $@ mailsnarf.o buf.o pcaputil.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB)
113
114 msgsnarf: msgsnarf.o buf.o pcaputil.o
115 $(CC) $(LDFLAGS) -o $@ msgsnarf.o buf.o pcaputil.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB)
116
117 sshmitm: sshmitm.o buf.o hex.o record.o ssh.o sshcrypto.o
118 $(CC) $(LDFLAGS) -o $@ sshmitm.o buf.o hex.o record.o ssh.o sshcrypto.o $(LIBS) $(LNETLIB) $(DBLIB) $(SSLLIB)
119
120 sshow: sshow.o pcaputil.o
121 $(CC) $(LDFLAGS) -o $@ sshow.o pcaputil.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB)
122
123 tcpkill: tcpkill.o pcaputil.o
124 $(CC) $(LDFLAGS) -o $@ tcpkill.o pcaputil.o $(LIBS) $(PCAPLIB) $(LNETLIB)
125
126 tcpnice: tcpnice.o pcaputil.o
127 $(CC) $(LDFLAGS) -o $@ tcpnice.o pcaputil.o $(LIBS) $(PCAPLIB) $(LNETLIB)
128
129 tcphijack: tcphijack.o pcaputil.o
130 $(CC) $(LDFLAGS) -o $@ tcphijack.o pcaputil.o $(LIBS) $(PCAPLIB) $(LNETLIB)
131
132 urlsnarf: urlsnarf.o base64.o buf.o pcaputil.o
133 $(CC) $(LDFLAGS) -o $@ urlsnarf.o base64.o buf.o pcaputil.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB)
134
135 webmitm: webmitm.o base64.o buf.o decode_http.o record.o
136 $(CC) $(LDFLAGS) -o $@ webmitm.o base64.o buf.o decode_http.o record.o $(LIBS) $(LNETLIB) $(DBLIB) $(SSLLIB)
137
138 webspy: webspy.o base64.o buf.o remote.o
139 $(CC) $(LDFLAGS) -o $@ webspy.o base64.o buf.o remote.o $(LIBS) $(NIDSLIB) $(PCAPLIB) $(LNETLIB) $(X11LIB)
140
141 install:
142 test -d $(install_prefix)$(sbindir) || \
143 $(INSTALL) -d $(install_prefix)$(sbindir)
144 for file in $(PROGS); do \
145 $(INSTALL_PROGRAM) -m 755 $$file $(install_prefix)$(sbindir); \
146 done
147 test -d $(install_prefix)$(libdir) || \
148 $(INSTALL) -d $(install_prefix)$(libdir)
149 for file in $(CONFIGS); do \
150 $(INSTALL_DATA) $$file $(install_prefix)$(libdir); \
151 done
152 test -d $(install_prefix)$(mandir)/man8 || \
153 $(INSTALL) -d $(install_prefix)$(mandir)/man8
154 for file in *.8; do \
155 $(INSTALL_DATA) $$file $(install_prefix)$(mandir)/man8; \
156 done
157
158 clean:
159 rm -f *.o *~ $(GEN) libmissing.a $(PROGS) webmitm.crt
160
161 distclean: clean
162 rm -f Makefile config.h config.cache config.log config.status
163
164 # EOF
Something went wrong with that request. Please try again.