]>
Commit | Line | Data |
---|---|---|
5697b842 | 1 | diff -urP tt/mgetty-current-plus-ring-patch/Makefile TT2/Makefile |
2 | --- tt/mgetty-current-plus-ring-patch/Makefile Mon Mar 1 20:00:00 1999 | |
3 | +++ TT2/Makefile Sat Jan 30 19:53:05 1999 | |
4 | @@ -107,7 +107,7 @@ | |
5 | # prompt first. Don't forget to activate the /AutoPPP/ line in login.config! | |
6 | # | |
7 | #CFLAGS=-Wall -O2 -pipe -DSECUREWARE -DUSE_POLL | |
8 | -CFLAGS=$(RPM_OPT_FLAGS) -Wall -pipe -DAUTO_PPP | |
9 | +CFLAGS=$(RPM_OPT_FLAGS) -Wall -pipe -DAUTO_PPP -DFIFO -DMSC98_WILDMAT_ANALYZE -DMSC98_EXTENDED_CND_SCRIPT -DMSC98_PASS_CID_CND_TO_VGETTY | |
10 | #CFLAGS=-O -DSVR4 | |
11 | #CFLAGS=-O -DSVR4 -DSVR42 | |
12 | #CFLAGS=-O -DUSE_POLL | |
5697b842 | 13 | @@ -450,9 +450,6 @@ |
14 | ||
15 | diff: mgetty$(DIFFR)-$(MR).$(SR).diff.gz | |
16 | ||
17 | -sign: tar | |
18 | - pgp -sab mgetty$(MR).$(SR).tar.gz | |
49e983c0 SS |
19 | - chmod +r mgetty$(MR).$(SR).tar.gz.asc |
20 | ||
5697b842 | 21 | mgetty$(DIFFR)-$(MR).$(SR).diff.gz: \ |
22 | mgetty$(DIFFR).tar.gz mgetty$(MR).$(SR).tar.gz | |
5697b842 | 23 | @@ -477,7 +474,7 @@ |
24 | # this is for automatic uploading to the beta site. | |
25 | # DO NOT USE IT if you're not ME! Please! | |
26 | # | |
27 | -beta: tar diff sign | |
28 | +beta: mgetty$(MR).$(SR).tar.gz diff | |
29 | test `hostname` = greenie.muc.de || exit 1 | |
30 | # local | |
31 | cp mgetty$(MR).$(SR).tar.gz /pub/mgetty-archive/ | |
32 | @@ -650,13 +647,6 @@ | |
33 | MAN8DIR=$(MAN8DIR) \ | |
34 | INFODIR=$(INFODIR) | |
35 | ||
36 | -# | |
37 | -# WWW frontend stuff | |
38 | -# | |
39 | -install.www: | |
40 | - cd frontends/www ; $(MAKE) install.www INSTALL="$(INSTALL)" \ | |
41 | - BINDIR=$(BINDIR) \ | |
42 | - LIBDIR=$(LIBDIR) CONFDIR=$(CONFDIR) | |
43 | # | |
44 | # voice extensions, consult the `voice' chapter in the documentation | |
45 | # | |
46 | diff -urP tt/mgetty-current-plus-ring-patch/mgetty.c TT2/mgetty.c | |
47 | --- tt/mgetty-current-plus-ring-patch/mgetty.c Mon Mar 1 20:00:04 1999 | |
48 | +++ TT2/mgetty.c Sat Jan 30 19:53:17 1999 | |
49 | @@ -803,6 +803,84 @@ | |
50 | ||
51 | /* Check Caller ID. Static table first, then cnd-program. */ | |
52 | ||
53 | +#ifdef MSC98_EXTENDED_CND_SCRIPT | |
54 | + if (!cndlookup()) { | |
55 | + lprintf(L_AUDIT, | |
56 | + "config denied caller dev=%s, pid=%d, caller='%s'", | |
57 | + Device, | |
58 | + getpid(), | |
59 | + CallerId); | |
60 | + clean_line(STDIN, 80); /* wait for ringing to stop */ | |
61 | + | |
62 | + mgetty_state = St_go_to_jail; | |
63 | + break; | |
64 | + } | |
65 | + else if (c_isset(cnd_program)) { | |
66 | +#define BOOL int | |
67 | + BOOL break_it = FALSE; | |
68 | + | |
69 | + switch (cnd_call(c_string(cnd_program), | |
70 | + Device, | |
71 | + dist_ring)) { | |
72 | + case CND_SCRIPT_ACCEPT_CALL: | |
73 | + break; | |
74 | + case CND_SCRIPT_LET_IT_RING: | |
75 | + lprintf(L_AUDIT, | |
76 | + "CND script denied caller dev=%s, pid=%d, caller='%s'", | |
77 | + Device, | |
78 | + getpid(), | |
79 | + CallerId); | |
80 | + clean_line(STDIN, 80); /* wait for ringing to stop */ | |
81 | + | |
82 | + mgetty_state = St_go_to_jail; | |
83 | + break_it = TRUE; | |
84 | + break; | |
85 | + case CND_SCRIPT_REJECT_CALL: | |
86 | + /* BUGS | |
87 | + * - Reject call, which should in all the cases tell | |
88 | + * BUSY to the caller, is not implemented yet. | |
89 | + * We maybe do not need it really. | |
90 | + */ | |
91 | + case CND_SCRIPT_IGNORE_CALL: | |
92 | + lprintf(L_AUDIT, | |
93 | + "CND script ignore/reject caller dev=%s, pid=%d, caller='%s'", | |
94 | + Device, | |
95 | + getpid(), | |
96 | + CallerId); | |
97 | + /* BUGS | |
98 | + * - This is probably modem-specific and should be | |
99 | + * in the modem specific voice library. | |
100 | + * NOTES | |
101 | + * - For the ZyXEL 2864i, firmware 2.11, this | |
102 | + * return BUSY to the caller if no other device | |
103 | + * is ringing (e.g. unexistant or BUSY). Else | |
104 | + * it continues to ring without the ZyXEL ringing. | |
105 | + */ | |
106 | + mdm_command("ATH", STDIN); | |
107 | + clean_line(STDIN, 80); /* wait for ringing to stop, | |
108 | + * theoretically no use here | |
109 | + */ | |
110 | + | |
111 | + mgetty_state = St_go_to_jail; | |
112 | + break_it = TRUE; | |
113 | + break; | |
114 | + case CND_SCRIPT_MORE_RINGS_NEEDED: | |
115 | + break_it = TRUE; | |
116 | + break; | |
117 | + default: | |
118 | + lprintf(L_FATAL, | |
119 | + "unknown result from CND script dev=%s, pid=%d, caller='%s'", | |
120 | + Device, | |
121 | + getpid(), | |
122 | + CallerId); | |
123 | + break; | |
124 | + } | |
125 | + | |
126 | + if (break_it) { | |
127 | + break; | |
128 | + } | |
129 | + } | |
130 | +#else /* MSC98_EXTENDED_CND_SCRIPT */ | |
131 | if ( !cndlookup() || | |
132 | ( c_isset(cnd_program) && | |
133 | cnd_call( c_string(cnd_program), Device, dist_ring ) == 1)) | |
134 | @@ -814,6 +892,7 @@ | |
135 | mgetty_state = St_go_to_jail; | |
136 | break; | |
137 | } | |
138 | +#endif /* MSC98_EXTENDED_CND_SCRIPT */ | |
139 | ||
140 | /* from here, there's no way back. Either the call will succeed | |
141 | and mgetty will exec() something else, or it will fail and | |
142 | diff -urP tt/mgetty-current-plus-ring-patch/mgetty.h TT2/mgetty.h | |
143 | --- tt/mgetty-current-plus-ring-patch/mgetty.h Mon Mar 1 20:00:04 1999 | |
144 | +++ TT2/mgetty.h Sat Jan 30 19:53:27 1999 | |
145 | @@ -11,6 +11,18 @@ | |
146 | ||
147 | #include "ugly.h" | |
148 | ||
149 | +/* BUGS | |
150 | + * - Those definitions should be in the interface file for | |
151 | + * the cnd.c module. | |
152 | + * - The code from the script is really that code << 8, see | |
153 | + * cnd_call() in cnd.c. | |
154 | + */ | |
155 | +#define CND_SCRIPT_ACCEPT_CALL 0 | |
156 | +#define CND_SCRIPT_IGNORE_CALL 1 | |
157 | +#define CND_SCRIPT_REJECT_CALL 2 | |
158 | +#define CND_SCRIPT_MORE_RINGS_NEEDED 3 | |
159 | +#define CND_SCRIPT_LET_IT_RING 4 | |
160 | + | |
161 | /* some generic, useful defines */ | |
162 | ||
163 | #ifndef ERROR |