File: settings.tmpl

package info (click to toggle)
znc 1.10.1-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 12,164 kB
  • sloc: cpp: 58,072; javascript: 11,859; python: 1,635; perl: 1,229; tcl: 219; sh: 200; ansic: 187; makefile: 82
file content (303 lines) | stat: -rw-r--r-- 12,837 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
<? I18N znc-webadmin ?>
<? INC Header.tmpl ?>

<div class="section">

	<h3><? FORMAT "Listen Port(s)" ?></h3>
	<div class="sectionbg">
		<div class="sectionbody">
			<div class="subsection">
				<table>
					<thead>
						<tr>
						    <th><? FORMAT "Port" ?></th>
						    <th><? FORMAT "BindHost" ?></th>
						    <th><? FORMAT "IPv4" ?></th>
						    <th><? FORMAT "IPv6" ?></th>
						    <th><? FORMAT "SSL" ?></th>
						    <th><? FORMAT "IRC" ?></th>
						    <th><? FORMAT "HTTP" ?></th>
						    <th><? FORMAT "URIPrefix" ?></th>
						    <th><? FORMAT "Delete" ?></th>
						</tr>
					</thead>
					<? LOOP ListenLoop ?>
					<? IF Type == "TCP" ?>
					<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
						<td><? VAR Port ?></td>
						<td><? VAR BindHost DEFAULT=** ?></td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsIPV4 ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsIPV6 ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td class="listener_show_ssl">
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsSSL ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsIRC ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsHTTP ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td><? VAR URIPrefix ?></td>
						<td>
							<? IF SuggestDeletion ?>
							<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>del_listener" method="post">
								<? INC _csrf_check.tmpl ?>
								<input name="type" type="hidden" value="<? VAR Type ?>"/>
								<input name="host" type="hidden" value="<? VAR BindHost ?>"/>
								<input name="port" type="hidden" value="<? VAR Port ?>"/>
								<input name="ipv4" type="hidden" value="<? VAR IsIPV4 ?>"/>
								<input name="ipv6" type="hidden" value="<? VAR IsIPV6 ?>"/>
								<input type="submit" value="<? FORMAT "Del" ?>"/>
							</form>
							<? ELSE ?>
							<input type="button" disabled="disabled" title="<? FORMAT "To delete port which you use to access webadmin itself, either connect to webadmin via another port, or do it in IRC (/znc DelPort)" ?>" value="<? FORMAT "Current" ?>"/>
							<? ENDIF ?>
						</td>
					</tr>
					<? ENDIF ?>
					<? ENDLOOP ?>
					<tr>
						<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>add_listener" method="post">
							<? INC _csrf_check.tmpl ?>
							<input name="type" type="hidden" value="TCP"/>
							<td><input name="port" type="number" min="1" max="65535" class="number third"/></td>
							<td><input name="host" type="text" value="*" class="sixth"/></td>
							<td><div class="checkbox"><input name="ipv4" type="checkbox" checked="checked"/></div></td>
							<td><div class="checkbox"><input name="ipv6" type="checkbox" checked="checked"/></div></td>
							<td><div class="checkbox"><input name="ssl" type="checkbox"/></div></td>
							<td><div class="checkbox"><input name="irc" type="checkbox" checked="checked"/></div></td>
							<td><div class="checkbox"><input name="web" type="checkbox" checked="checked"/></div></td>
							<td><input name="uriprefix" type="text" value="/" class="sixth"/></td>
							<td><input type="submit" value="<? FORMAT "Add" ?>"/></td>
						</form>
					</tr>
				</table>
			</div>

			<div class="subsection">
				<table>
					<thead>
						<tr>
						    <th><? FORMAT "Path" ?></th>
						    <th><? FORMAT "Mode" ?></th>
						    <th><? FORMAT "Group" ?></th>
						    <th><? FORMAT "SSL" ?></th>
						    <th><? FORMAT "IRC" ?></th>
						    <th><? FORMAT "HTTP" ?></th>
						    <th><? FORMAT "URIPrefix" ?></th>
						    <th><? FORMAT "Delete" ?></th>
						</tr>
					</thead>

					<? LOOP ListenLoop ?>
					<? IF Type == "Unix" ?>
					<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
						<td>unix:<? VAR Path ?></td>
						<td><? VAR Mode ?></td>
						<td><? VAR Group ?></td>
						<td class="listener_show_ssl">
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsSSL ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsIRC ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td>
							<div class="checkbox"><input type="checkbox" disabled="disabled" <? IF IsHTTP ?>checked="checked"<? ENDIF ?>/></div>
						</td>
						<td><? VAR URIPrefix ?></td>
						<td>
							<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>del_listener" method="post">
								<? INC _csrf_check.tmpl ?>
								<input name="type" type="hidden" value="<? VAR Type ?>"/>
								<input name="path" type="hidden" value="<? VAR Path ?>"/>
								<input type="submit" value="<? FORMAT "Del" ?>"/>
							</form>
						</td>
					</tr>
					<? ENDIF ?>
					<? ENDLOOP ?>
					<tr>
						<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>add_listener" method="post">
							<? INC _csrf_check.tmpl ?>
							<input name="type" type="hidden" value="Unix"/>
							<td>unix:<input name="path" type="text" value="/" class="third"/></td>
							<td><input name="mode" type="number" min="-1" max="777" class="number third" value="-1" title="<? FORMAT "Octal number; -1 means do not chmod" ?>"/></td>
							<td><input name="group" type="text" value="" class="sixth"/></td>
							<td><div class="checkbox"><input name="ssl" type="checkbox"/></div></td>
							<td><div class="checkbox"><input name="irc" type="checkbox" checked="checked"/></div></td>
							<td><div class="checkbox"><input name="web" type="checkbox" checked="checked"/></div></td>
							<td><input name="uriprefix" type="text" value="/" class="sixth"/></td>
							<td><input type="submit" value="<? FORMAT "Add" ?>"/></td>
						</form>
					</tr>
				</table>
			</div>
		</div>
	</div>
</div>

<form action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>settings" method="post">
	<? INC _csrf_check.tmpl ?>
	<input type="hidden" name="submitted" value="1" />

	<div class="section">
		<h3><? FORMAT "Settings" ?></h3>
		<div class="sectionbg">
			<div class="sectionbody">
				<div class="subsection">
					<div class="inputlabel"><label for="skin"><? FORMAT "Skin:" ?></label></div>

						<select id="skin" name="skin">
							<? LOOP SkinLoop ?>
							<option value="<? VAR Name ?>"<? IF Checked ?> selected="selected"<? ENDIF ?>><? IF Name == "_default_" ?><? FORMAT "Default" ?><? ELSE ?><? VAR Name ?><? ENDIF ?></option>
							<? ENDLOOP ?>
						</select>

				</div>


				<div class="subsection third">
					<div class="inputlabel"><label for="statusprefix"><? FORMAT "Status prefix:" ?></label></div>
					<input id="statusprefix" type="text" name="statusprefix" value="<? VAR StatusPrefix ?>"
						   title="<? FORMAT "The prefix for the status and module queries." ?>"/>
					<br /><span class="info"><? FORMAT "Default for new users only." ?></span>
				</div>


				<div class="subsection half">
					<div class="inputlabel"><label for="maxbufsize"><? FORMAT "Maximum buffer size:" ?></label></div>
					<input id="maxbufsize" type="number" name="maxbufsize" value="<? VAR MaxBufferSize ?>"
						   title="<? FORMAT "Sets the global Max Buffer Size a user can have." ?>"/>
				</div>


				<div class="subsection half">
					<div class="inputlabel"><label for="connectdelay"><? FORMAT "Connect delay:" ?></label></div>
					<input id="connectdelay" type="number" name="connectdelay" value="<? VAR ConnectDelay ?>"
						   title="<? FORMAT "The time between connection attempts to IRC servers, in seconds. This affects the connection between ZNC and the IRC server; not the connection between your IRC client and ZNC." ?>"/>
				</div>


				<div class="subsection half">
					<div class="inputlabel"><label for="serverthrottle"><? FORMAT "Server throttle:" ?></label></div>
					<input id="serverthrottle" type="number" name="serverthrottle" value="<? VAR ServerThrottle ?>"
						   title="<? FORMAT "The minimal time between two connect attempts to the same hostname, in seconds. Some servers refuse your connection if you reconnect too fast." ?>"/>
				</div>


				<div class="subsection half">
					<div class="inputlabel"><label for="anoniplimit"><? FORMAT "Anonymous connection limit per IP:" ?></label></div>
					<input id="anoniplimit" type="number" name="anoniplimit" value="<? VAR AnonIPLimit ?>"
						   title="<? FORMAT "Limits the number of unidentified connections per IP." ?>"/>
				</div>


				<div class="subsection">
					<div class="inputlabel"><? FORMAT "Protect web sessions:" ?></div>
					<div class="checkbox"><input type="checkbox" name="protectwebsessions" id="protectwebsessions_checkbox"<? IF ProtectWebSessions ?> checked="checked"<? ENDIF ?> />
						<label for="protectwebsessions_checkbox"><? FORMAT "Disallow IP changing during each web session" ?></label></div>
				</div>


				<div class="subsection">
					<div class="inputlabel"><? FORMAT "Hide ZNC version:" ?></div>
					<div class="checkbox"><input type="checkbox" name="hideversion" id="hideversion_checkbox"<? IF HideVersion ?> checked="checked"<? ENDIF ?> />
						<label for="hideversion_checkbox"><? FORMAT "Hide version number from non-ZNC users" ?></label></div>
				</div>

				<div class="subsection">
					<div class="inputlabel"><? FORMAT "Auth only via module:" ?></div>
					<div class="checkbox"><input type="checkbox" name="authonlyviamodule" id="authonlyviamodule_checkbox"<? IF AuthOnlyViaModule ?> checked="checked"<? ENDIF ?> />
						<label for="authonlyviamodule_checkbox"><? FORMAT "Allow user authentication by external modules only" ?></label></div>
				</div>


				<div class="subsection twothird">
					<div class="inputlabel"><label for="motd"><? FORMAT "MOTD:" ?></label></div>
					<textarea id="motd" name="motd" cols="70" rows="5" class="monospace"><? LOOP MOTDLoop ?><? VAR Line ?>
<? ENDLOOP ?>
</textarea>
					<br /><span class="info"><? FORMAT "“Message of the Day”, sent to all ZNC users on connect." ?></span>
				</div>

			</div>
		</div>
	</div>

	<div class="section">
		<h3><? FORMAT "Global Modules" ?></h3>
		<div class="sectionbg">
			<div class="sectionbody">
				<table>
					<thead>
					<tr>
						<th><? FORMAT "Name" ?></th>
						<th><? FORMAT "Arguments" ?></th>
						<th><? FORMAT "Description" ?></th>
						<th><? FORMAT "Loaded by networks" ?></th>
						<th><? FORMAT "Loaded by users" ?></th>
					</tr>
					</thead>
					<tbody>
					<? LOOP ModuleLoop ?>
					<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
						<td class="mod_name">
							<input type="checkbox" name="loadmod" id="lm_<? VAR Name ?>" value="<? VAR Name ?>"
							<? IF Checked ?> checked="checked"<? ENDIF ?>
							<? IF Disabled ?> disabled="disabled"<? ENDIF ?> />
							<label for="lm_<? VAR Name ?>">
							<? IF Wiki ?><a href="https://wiki.znc.in/<? VAR Wiki ?>" target="_blank" class="external"><? VAR Name ?></a>
							<? ELSE ?> <? VAR Name ?> <? ENDIF ?></label>
						</td>
						<td class="mod_args">
							<input type="text" name="modargs_<? VAR Name ?>" value="<? VAR Args ?>"
							<? IF !HasArgs ?> disabled="disabled"<? ENDIF ?>
							<? IF ArgsHelpText ?> title="<? VAR ArgsHelpText ?>"<? ENDIF ?> />
						</td>
						<td class="mod_descr"><? VAR Description ?></td>
						<td class="center">
							<? IF CanBeLoadedByNetwork ?>
								<input type="checkbox" name="loaded_by_network" id="loaded_by_net_<? VAR Name ?>"
								<? IF LoadedBySomeNetworks && LoadedByAllNetworks ?>
									checked="checked"
								<? ENDIF ?>
								disabled="disabled"/>
								<? IF LoadedBySomeNetworks && !LoadedByAllNetworks ?>
									<script type="text/javascript">
										document.getElementById("loaded_by_net_<? VAR Name ?>").indeterminate = true;
									</script>
								<? ENDIF ?>
							<? ENDIF ?>
						</td>
						<td class="center">
							<? IF CanBeLoadedByUser ?>
								<input type="checkbox" name="loaded_by_user" id="loaded_by_user_<? VAR Name ?>"
								<? IF LoadedBySomeUsers && LoadedByAllUsers ?>
									checked="checked"
								<? ENDIF ?>
								disabled="disabled"/>
								<? IF LoadedBySomeUsers && !LoadedByAllUsers ?>
									<script type="text/javascript">
										document.getElementById("loaded_by_user_<? VAR Name ?>").indeterminate = true;
									</script>
								<? ENDIF ?>
							<? ENDIF ?>
						</td>
					</tr>
					<? ENDLOOP ?>
					</tbody>
				</table>
			</div>
		</div>
	</div>

	<div class="submitline">
		<input type="submit" value="<? FORMAT "Save" ?>"/>
	</div>
</form>

<? INC Footer.tmpl ?>