ChangeLog 100 KB
Newer Older
Niels Möller's avatar
Niels Möller committed
1
2
3
4
5
2002-01-22  Niels Mller  <nisse@cuckoo.hack.org>

	* src/scm/gaba.scm (make-class): Added FIXME:-comment about
	offsetof. 

Niels Möller's avatar
Niels Möller committed
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
2002-01-21  Niels Mller  <nisse@cuckoo.hack.org>

	* src/xalloc.h (NEW_VAR_OBJECT, CLONE_VAR_OBJECT,
	CLONED_VAR_OBJECT): New macros. 

	* src/xalloc.c (lsh_var_alloc): New function.
	(lsh_object_alloc): Use lsh_var_alloc.
	(lsh_var_clone): New function.
	(lsh_object_clone): Use lsh_var_clone.

	* src/list.c (lsh_list_alloc): Moved function here, from xalloc.c.
	Now uses lsh_var_alloc.

2002-01-20  Niels Mller  <nisse@cuckoo.hack.org>

	* src/crypto.c (hash_update, hash_digest, hash_copy, make_hash):
	New functions using struct nettle_hash.
	(make_hmac_algorithm): Reorganized hmac implementation again. Now
	uses struct nettle_hash.
	Updated all users.

	* src/algorithms.c (all_symmetric_algorithms): Changed back to use
	make_hmac_algorithm. 

	* src/abstract_crypto.h (hash_instance): Rewrote, use nettle,
	replaced methods with ordinary functions.
	(mac_instance): New class, before it was just analias for
	hash_instance.

	* src/Makefile.am.in (liblsh_a_SOURCES): Removed md5.c and sha.c. 

2002-01-17  Niels Mller  <nisse@cuckoo.hack.org>

	* src/md5.c, src/sha.c: Deleted files. The wrapper code was moved
	to crypto.c, and now uses struct nettle_hash.

2002-01-16  Niels Mller  <nisse@cuckoo.hack.org>

	* src/pkcs5-test.c (main): Use crypto_hmac_sha1_algorithm.

	* src/lock_file.c (do_lsh_file_lock): Improved error message.

	* src/algorithms.c (all_symmetric_algorithms): Don't use
	make_hmac_algorithm. 

	* src/crypto.c: Rewrote the hmac code to use Nettle.

	* src/hmac.c, src/Makefile.am.in: Deleted file hmac.c.

Niels Möller's avatar
Niels Möller committed
55
56
2002-01-14  Niels Mller  <nisse@cuckoo.hack.org>

Niels Möller's avatar
Niels Möller committed
57
58
59
60
	* src/rsa.c (make_rsa_signer): Take advantage of rsa_public_key
	and rsa_private_key being independent structs now. General cleanup
	and deletion of old code.

Niels Möller's avatar
Niels Möller committed
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
	* src/spki.c (spki_hash_sexp): Bugfix, don't hash the data once.
	Bug reported by Werner Koch.

	* src/sexp_parser.c (sexp_parse): Added advanced-hex syntax, as an
	alias for the ordinary (but not implemented) advanced syntax.

	* src/sexp.c: Added new format "advanced-hex" that uses hex
	instead of base64.
	(encode_hex): New function.

	* src/rsa_keygen.c (rsa_generate_key): Renamed key type to
	"rsa-pkcs1". 

	* src/rsa.c: Use nettle's rsa implementation. Deleted support for
	rsa-md5. Needs some more cleanup.

	* src/publickey_crypto.h: Moved rsa-related declarations here.

	* src/rsa.h: rsa.h is now obsolete.

	* src/lsh.c (read_user_keys): Added ATOM_RSA_PKCS1.
	* src/server.c (read_host_key): Likewise.

	* src/format.c (format_hex_string): Export this function.

	* src/atoms.in: Added "rsa-pkcs1".

	* src/algorithms.c (all_signature_algorithms): Deleted support for
	rsa-md5. 

2002-01-13  Niels Mller  <nisse@cuckoo.hack.org>

	* configure.in (lsh_cv_c_attribute): Consider __FUNCTION__ broken
	in gcc-3.

Niels Möller's avatar
Niels Möller committed
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
2002-01-09  Niels Mller  <nisse@cuckoo.hack.org>

	* src/dsa.c (dsa_hash): Don't call sha1_final.
	* src/dsa_keygen.c (hash): Likewise.

	* src/lsh.h (struct lsh_string_header): Empty structs are not
	allowed by ANSI-C, so don't declare this one unless debugging is
	enabled. 

	* src/lsh_proxy.c: Don't use randomness_with_poll.

	* src/lshd.c (main): Pass the correct type to make_simple_kexinit.

	* src/md5.c (do_md5_digest): Don't call md5_final and md5_init. 

	* src/sha.c (do_sha_digest): Don't call sha1_final and sha1_init. 

	* src/rsync/generate.c, src/rsync/receive.c, src/rsync/send.c:
	Removed calls of md5_final.

Niels Möller's avatar
Niels Möller committed
116
117
118
119
2001-12-16  Niels Mller  <nisse@cuckoo.hack.org>

	* Released lsh-1.3.6.

Niels Möller's avatar
Niels Möller committed
120
121
122
123
124
125
126
127
128
129
130
2001-12-16  Niels Mller  <nisse@lysator.liu.se>

	* src/lock_file.c: Include sys/types.h and sys/stat.h, needed on
	Solaris. 

2001-12-14  Niels Mller  <nisse@lysator.liu.se>

	* src/dsa_keygen.c (dsa_generate_key): Fixed declaration and code
	mixup. 
	* src/rsa_keygen.c (rsa_generate_key): Likewise.

Niels Möller's avatar
Niels Möller committed
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
2001-12-14  Niels Mller  <nisse@cuckoo.hack.org>

	* src/testsuite/Makefile.am (CLEANFILES, DISTCLEANFILES): Added
	fiels generated by the test, in order to make make distcheck
	happy. 

	* src/used_headers: Update for automake-1.5, dependency files are
	now named foo.Po.

	* src/Makefile.am.in: Changed rules for prime_table.h and
	digit_table.h. Now they depend only on the source file, not on the
	executable. 

	* doc/lsh.texinfo (lsh-make-seed): New section.
	(Files and environment variables): Wrote a file list.

2001-12-12  Niels Mller  <nisse@cuckoo.hack.org>

	* doc/lsh.texinfo (Files and environment variables): Documented
	environment variables.

	* misc/make-dist: Deleted the strip_rsa function.

	* src/testsuite/functions.sh (LSH_YARROW_SEED_FILE): Export
	variable. Also create the seed file if needed.

	* src/testsuite/seed-test: Use the -q --sloppy flags when invoking
	lsh-make-seed. 

	* src/sexp.c (sexp_format): Add newline at the end of the
	"advanced" syntax representation. Changed all internal uses of
	sexp_format to use the method SEXP_FORMAT instead.

	* src/sexp-conv.c (main): Deleted code for newline-terminating
	output. 

	* src/rsa.c (make_rsa_signer): Call mpz_init for all bignum
	instance variables.

	* src/lsh-make-seed.c: New option --server.
	(main): If invoked with the quiet option (-q), never ask the user
	to type randomly.

	* src/lock_file.h (LSH_FILE_LOCK): New argument RETRIES.

	* src/lock_file.c (do_lsh_file_lock): If locking fails,
	optionally retry a few times.

	* src/client_x11.c (make_forward_x11): Assert that the randomness
	generator is of "good" quality.
	* src/rsa_keygen.c (rsa_generate_key): Likewise.
	* src/keyexchange.c (make_simple_kexinit): Likewise.
	* src/dsa_keygen.c (dsa_generate_key): Likewise.
	* src/dsa.c (generic_dsa_sign): Likewise.
	* src/dh_exchange.c (make_dh): Likewise.

	* src/Makefile.am.in (sbin_PROGRAMS): Install lsh-krb-checkpw in
	$prefix/sbin, not $prefix/bin.

	* src/randomness.c: Deleted old generators.

	* src/randomness.h: Deleted all classes but randomness. New method
	RANDOM_ADD. 

	* src/unix_random.c: Rewrote to use yarrow. Updated users.

	* src/werror.c (werror_progress): Fixed test of verbose and quite
	flags. 

2001-12-08  Niels Mller  <nisse@cuckoo.hack.org>

	* src/lsh-pam-checkpw.c: New helper program for verifying
	passwords against PAM. Written by Pontus Skld.

2001-12-07  Niels Mller  <nisse@cuckoo.hack.org>

	* src/unix_user.c: Added comments on how to fix use of setuid.

	* src/lsh-make-seed.c: Added option --sloppy.

	* src/lsh-execuv.c: New file. Helper program for securely exec:ing
	user programs. 

Niels Möller's avatar
Niels Möller committed
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
2001-12-05  Niels Mller  <nisse@cuckoo.hack.org>

	* src/werror.c (werror_progress): New function.

	* src/ssh-conv: Shortened if-statement.

	* src/lsh-make-seed.c (main_argp_parser): Use the right default
	file name.
	(get_dev_mem): #if:ed out this code, it's dangerous on some
	systems.
	(get_system): Implemented this, including reading some /proc
	files. Implemented
	(get_interact): Implemented.
	(main): Move locking later, until we want to write the file.
	Implemented the actual writing of the seed-file data.

	* src/lsh-authorize: Fixed bash-isms, don't use "if !", use "$HOME"
	rather than "~".

	* src/lock_file.c (do_lsh_file_lock): Initialize info attribute in
	new object.
	(do_lsh_file_lock_p): New function, corresponding to a new method
	for checking if a lock exists, without creating one.

	* src/client_x11.c (make_client_x11_display): Fixed werror format
	string. 

	* src/channel_forward.c: Use CAST_SUBTYPE in channel_forward's
	methods. Needed because it is subclassed as client_x11_channel.

	* src/Makefile.am.in (liblsh_a_SOURCES): Added lock_file.c.

2001-12-02  Niels Mller  <nisse@cuckoo.hack.org>

	* src/lock_file.c, src/lock_file.c: New files. Locking mechanism
	for the seed file.

Niels Möller's avatar
Niels Möller committed
251
252
253
254
255
256
257
258
259
260
2001-11-23  Niels Mller  <nisse@ehand.com>

	* src/sftp/sftp-server.c (sftp_process_readdir): Clear errno
	before calling readdir.

2001-11-22  Niels Mller  <nisse@ehand.com>

	* src/sftp/sftp-server.c (sftp_attrib_from_stat): Bugfix, use |,
	not ||. Noticed by Pontus Skld.

Niels Möller's avatar
Niels Möller committed
261
262
263
264
265
266
267
268
2001-11-20  Niels Mller  <nisse@ehand.com>

	* src/zlib.c (make_zlib_instance): Check return valus from
	inflateInit and deflateInit.

	* src/lsh-make-seed.c (update_zlib): New function.
	(get_dev_mem): Implemented reading of /dev/mem.

Niels Möller's avatar
Niels Möller committed
269
270
271
272
273
2001-11-14  Niels Mller  <nisse@cuckoo.hack.org>

	* src/lsh-make-seed.c (get_dev_random): Implement reading of
	/dev/random.

Niels Möller's avatar
Niels Möller committed
274
275
276
277
278
279
280
281
282
2001-11-14  Niels Mller  <nisse@ehand.com>

	* src/Makefile.am.in (bin_PROGRAMS): Added lsh-make-seed.

	* src/lsh-make-seed.c: New program, for creating the initial seed
	file. 

	* src/testsuite/seed-test: New file, testing lsh-make-seed.

Niels Möller's avatar
Niels Möller committed
283
284
285
286
2001-11-06  Niels Mller  <nisse@cuckoo.hack.org>

	* configure.in: Bumped version to 1.3.6.

Niels Möller's avatar
Niels Möller committed
287
288
289
290
291
2001-11-02  Niels Mller  <nisse@ehand.com>

	* src/server_session.c (do_eof): Use close_fd_write instead of
	close_fd_nicely. 

Niels Möller's avatar
Niels Möller committed
292
293
294
295
296
2001-10-30  Niels Mller  <nisse@lysator.liu.se>

	* src/client_session.c (make_client_session_channel): Added
	fixme-comment. 

Niels Möller's avatar
Niels Möller committed
297
298
299
300
301
302
303
304
305
306
307
2001-10-30  Niels Mller  <nisse@ehand.com>

	* src/channel_forward.c (do_channel_forward_eof): Don't call
	shutdown(), use close_fd_write instead.

	* src/io.c (do_write_callback): Use close_fd_write if buffer is
	closed and becomes empty.
	(close_fd_write): New function.

	* src/rsa.c: Comment fixes.

Niels Möller's avatar
Niels Möller committed
308
309
310
311
312
313
2001-10-29  Niels Mller  <nisse@ehand.com>

	* src/testsuite/Makefile.am (TS_MORE_SH): Added lshg-1-test.

	* src/server_session.c (do_eof): Signal EOF on the process' stdin. 

Niels Möller's avatar
Niels Möller committed
314
315
316
317
318
319
320
321
322
323
324
325
2001-10-26  Niels Mller  <nisse@ehand.com>

	* src/sftp/sftp-server.c (sftp_process_read): Use the same type
	for done as for length, UINT32.

	* src/xauth.c (xauth_lookup): Bugfix for ipv6 addresses.

2001-10-25  Niels Mller  <nisse@ehand.com>

	* src/sftp/buffer.c (READ_UINT64): Use off_t instead of UINT64,
	which isn't defined.

Niels Möller's avatar
Niels Möller committed
326
327
328
329
330
331
332
333
334
335
2001-10-24  Niels Mller  <nisse@ehand.com>

	* src/read_packet.c (do_read_packet): If we get EOF on a packet
	boundary, raise EXC_FINISH_READ, not EXC_PROTOCOL.

	* src/connection.c (do_exc_connection_handler): Added a comment
	for the EXC_FINISH_READ case.

	* configure.in (BASH): Unset BASH if it has the value "/bin/sh".

Niels Möller's avatar
Niels Möller committed
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
2001-10-23  Niels Mller  <nisse@cuckoo.hack.org>

	* src/testsuite/lshg-1-test: New test program.

	* src/client.c (make_subsystem_request): New function, contributed
	by Pontus Skld.
	(client_options): New option --subsystem.
	(client_subsystem_session): New function.
	(client_command_session): Don't ask for a pty by default.
	(client_maybe_pty): New argument default_pty.
	(client_argp_parser): Handle subsystem option.

2001-10-22  Niels Mller  <nisse@cuckoo.hack.org>

	* Makefile.am.in (MAINTAINERCLEANFILES): Don't use += for
	assigning this variable.
	* src/Makefile.am.in (MAINTAINERCLEANFILES): Likewise.

Niels Möller's avatar
Niels Möller committed
354
355
2001-10-15  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
356
357
	Released lsh-1.3.5.
	
Niels Möller's avatar
Niels Möller committed
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
	* src/testsuite/cast128-test.m4: New cast-128 cbc testcase.

	* src/crypto.c (crypto_cast128_cbc_algorithm): New algorithm,
	replacing the code in cast.c.
	(crypto_serpent256_cbc_algorithm): New algorithm, replacing the
	code in serpent.c

	* src/serpent.c, src/cast.c, src/blowfish.c, src/cbc.c,
	src/cascade.c: Deleted files.

	* src/abstract_crypto.c (crypto_invert): Deleted function.
	(gcd): Deleted function.
	(lcm): Deleted function.

	* src/crypto.c (crypto_serpent256_cbc_algorithm): New algorithm,
	replacing code in serpent.c.

	* src/testsuite/blowfish-test.m4: New testcase for blowfish-128
	cbc. 

	* src/crypto.c (crypto_blowfish_cbc_algorithm): New algorithm,
	replacing the code in blowfish.c.

	* src/Makefile.am.in (liblsh_a_SOURCES): Deleted blowfish.c.

	* src/testsuite/twofish-test.m4: Updated test case to test
	twofish_cbc. 

	* src/testsuite/des-test.m4: Updated test case to test des3_cbc.

	* src/idea.c: Deleted file.

	* src/des.c, src/twofish.c: Deleted files, replaced by code in
	crypto.c. 

	* src/crypto.c (crypto_twofish256_cbc_algorithm): New algorithm,
	replacing the code in twofish.c.
	(make_des3_cbc_instance): Initialize the iv properly.

Niels Möller's avatar
Niels Möller committed
397
398
399
400
401
402
403
404
405
406
407
408
2001-10-14  Niels Mller  <nisse@cuckoo.hack.org>

	* src/crypto.c (crypto_aes256_cbc_algorithm): Renamed, was
	aes256_cbc_algorithm. 
	(crypto_des3_cbc_algorithm): New algorithm, to replace the code in
	des.c. Doesn't quite work yet.

	* src/algorithms.c (all_symmetric_algorithms): Use
	crypto_des3_cbc_algorithm. 

	* src/Makefile.am.in (liblsh_a_SOURCES): Deleted des.c.

Niels Möller's avatar
Niels Möller committed
409
410
2001-10-05  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
411
412
413
	* src/arcfour.c, src/rijndael.c: Deleted files. Code moved to
	crypto.c.

Niels Möller's avatar
Niels Möller committed
414
415
416
417
418
419
420
421
422
423
424
	* src/testsuite/aes-test.m4: New testcase; NIST:s testcases for
	aes256-cbc. 

	* src/testsuite/macros.m4 (TS_TEST_CRYPTO): Added optional 6:th
	argument for iv.

	* src/testsuite/Makefile.am (TS_PROGS): Added aes-test.

	* src/crypto.h, src/crypto.c: Deleted aes128_cbc_algorithm and
	aes192_cbc_algorithm.

Niels Möller's avatar
Niels Möller committed
425
426
427
428
429
430
431
432
433
434
2001-10-05  Niels Mller  <nisse@cuckoo.hack.org>

	* src/crypto.c: New file, with glue to Nettle.

	* src/algorithms.c (all_symmetric_algorithms): Replaced references
	to rijndael_algorithm with aes256_cbc_algorithm.

	* src/Makefile.am.in (liblsh_a_SOURCES): Added crypto.c. Deleted
	arcfour.c and rijndael.c.

Niels Möller's avatar
Niels Möller committed
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
2001-10-03  Niels Mller  <nisse@ehand.com>

	* src/Makefile.am.in (liblsh_a_SOURCES): Deleted sexp_commands.c
	and spki_commands.c.

	* src/sexp_commands.c, src/sexp_commands.h, src/spki_commands.c,
	src/spki_commands.h: Deleted obsolete files.

	* src/lshd.c (options2keys): New command, that uses read_host_key,
	and replaces options2keyfile.
	* src/lsh_proxy.c: Likewise.

	* src/server.c (read_host_key): New function replacing
	spki_read_hostkey. 

	* src/spki_commands.c (make_pkcs5_decrypt): Deleted function.
	(do_spki_decrypt): Deleted function.
	(spki_password_decrypt): Deleted class.
	(make_spki_read_userkeys): Deleted function.
	(spki_read_userkeys): Deleted expression.
	(spki_return_userkeys): Deleted command.
	(spki_add_userkey_command): Deleted command.
	(do_spki_add_userkey): Deleted function.
	(spki_read_userkey_context): Deleted class.

	* src/spki.c (spki_sexp_to_signer): Added argument algorithm_name. 
	(spki_pkcs5_decrypt): New function, replacing make_pkcs5_decrypt.

	* src/lsh.c (read_user_keys): New function, replacing
	do_options2identities and make_spki_read_userkeys.

	* src/spki_commands.c (make_spki_read_acls): Deleted function. 
	(spki_read_acl): Deleted expression.
	(do_spki_add_acl): Deleted function.
	(spki_add_acl_command): Deleted command.
	(spki_command): Deleted class.
	(spki_signer2verifier): Deleted command.
	(spki_verifier2public): Deleted command.

	* src/resource.c (do_kill_all): Added trace message.

	* src/lsh.c (read_known_hosts): New function, replacing
	make_spki_read_acls. 
	(do_options2known_hosts): Deleted function.

	* src/client.c (make_client_session): Register the channel's
	resource list with the gc.

	* src/testsuite/lsh-7-test: New test, verifying that connecting,
	without a proper entry in known_hosts, fails.

	* src/testsuite/Makefile.am (TS_MORE_PROGS): Added lsh-7-test.

	* src/sexp_commands.c (make_sexp_print_raw_hash): Deleted
	function. 
	(sexp_print_raw_hash): Deleted command.
	(do_sexp_print): Deleted function.
	(make_sexp_print_command): Deleted function.
	(make_sexp_print_to): Deleted function.

	* src/spki.c (spki_sexp_to_signer): New function.
	(spki_pkcs5_encrypt): New function.

	* src/spki_commands.c (spki_sexp2signer_command): Deleted command,
	replaced with function spki_sexp_to_signer.
	(make_pkcs5_encrypt): Deleted, replaced with spki_pkcs5_encrypt
	function. 

	* src/lsh-writekey.c: Rewrote to use io_read_file_raw and
	write_raw, without using any commands or io_run.
	* src/lsh-decode-key.c: Likewise.

Niels Möller's avatar
Niels Möller committed
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
2001-10-03  Niels Mller  <nisse@cuckoo.hack.org>

	* src/lsh-export-key.c: No longer needs to include
	sexp_commands.h. 

	* src/server_keyexchange.c (server_srp_read_verifier): Renamed
	class (was srp_init_continuation) and changed super class to
	abstract_write.  
	(do_server_srp_read_verifier): Work with new USER_READ_FILE
	conventions. 
	(do_handle_srp_init): Likewise.

	* src/lsh.h: Forward declare abstract_write.

	* src/unix_user.c (exc_read_user_file_handler): New class.
	(do_read_file): Updated for new USER_READ_FILE conventions. 

	* src/userauth.h (lsh_user): Changed the arguments to
	USER_READ_FILE, now takes an abstract_write that will receive the
	file contents, not command_continuation.

Niels Möller's avatar
Niels Möller committed
528
529
530
531
532
533
534
535
536
537
538
2001-10-02  Niels Mller  <nisse@cuckoo.hack.org>

	* src/spki.c (spki_hash_sexp): New function.

	* src/spki_commands.c (make_spki_hash): Deleted function.
	(spki_hash): Deleted class.
	(spki_hash_md5): Deleted command.
	(spki_hash_sha1): Deleted command.

	* src/lsh-decode-key.c (do_decode_key): Free CONTENTS properly.

Niels Möller's avatar
Niels Möller committed
539
540
541
542
2001-10-02  Niels Mller  <nisse@ehand.com>

	* src/lsh-export-key.c (main): Rewrote to use io_read_file_raw and
	write_raw, without using any commands or io_run.
Niels Möller's avatar
Niels Möller committed
543
	* src/sexp-conv.c (main): Likewise.
Niels Möller's avatar
Niels Möller committed
544
545
546
547

	* src/io.c (io_read_file_raw): New function, for reading an entire
	file into a string. Uses string_buffer.

Niels Möller's avatar
Niels Möller committed
548
	* src/gc.c (gc_final): Check that root_set is non-null before
Niels Möller's avatar
Niels Möller committed
549
550
	calling KILL_RESOURCE_LIST.

Niels Möller's avatar
Niels Möller committed
551
552
553
554
555
556
557
558
559
2001-09-30  Niels Mller  <nisse@cuckoo.hack.org>

	* src/io.c (do_write_prepare): Deleted function.
	(do_consuming_read): Deleted old code to deal with fd->hanged_up. 
	(do_write_callback): Call write_buffer_pre_write instead of
	FD_PREPARE.

	* src/io.h (FD_PREPARE): Deleted method.

Niels Möller's avatar
Niels Möller committed
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
2001-09-28  Niels Mller  <nisse@cuckoo.hack.org>

	* src/server_session.c (do_eof): Use close_fd_nicely instead of
	write_buffer_close. 
	* src/sexp_test.c (do_close): Likewise.

	* src/io.c (do_write_close): Deleted function.
	(close_fd): Set the flag write_buffer->closed directly, instead of
	calling FD_WRITE_CLOSE.
	(close_fd_nicely): Don't use FD_WRITE_CLOSE, instead, set the
	write_buffer->closed flag, and close the fd if the write_buffer is
	empty. 

	* src/io.h (FD_WRITE_CLOSE): Deleted method.

	* src/write_buffer.c (write_buffer_close): Deleted. The closed
	flag is now set by close_fd and close_fd_nicely. Everybody else
	should be using those functions.

	* src/tcpforward_commands.c (install_forwarded_tcpip_handler):
	Static command deleted, not used anywhere.

Niels Möller's avatar
Niels Möller committed
582
583
584
585
586
587
588
589
590
591
592
593
594
2001-09-28  Niels Mller  <nisse@ehand.com>

	* src/tty.c (tty_setwinsize): Rows and columns were mixed up.
	Fixed.

	* src/server_session.c (make_pty): Reorganized to be more
	readable.
	(spawn_process): DEleted local variable uses_pty. Instead NULL
	session->pty if no pty is in use.
	(do_window_change_request): Use the fd connected to the process'
	stdin for manipulating the pty.
	(do_alloc_pty): Check that we haven't started a process already.

Niels Möller's avatar
Niels Möller committed
595
596
2001-09-27  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
597
598
599
600
601
602
	* src/server_session.h (window_change_request_handler): Declare
	object. 

	* src/lshd.c (main): Install window_change_request_handler for
	session channels.

Niels Möller's avatar
Niels Möller committed
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
	* src/tcpforward_commands.c: Made some more objects static.

	* src/spki_commands.c (spki_parse_key): Deleted class.
	(spki_sexp2signer_command): Define using DEFINE_COMMAND2.
	(spki_sexp2keypair_command): Likewise.
	
	* src/sexp.c: Use const struct sexp * in more places.

	* src/resource.c (dont_free_live_resource): Check that resource is
	dead. Don't look at gc_final_p.

	* src/lsh-export-key.c (do_ssh2_print_command): Updated for new
	sexp_check_type prototype.
	* src/spki.c: Likewise.
	* src/srp_exchange.c (make_srp_entry): Likewise.

Niels Möller's avatar
Niels Möller committed
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
2001-09-27  Niels Mller  <nisse@cuckoo.hack.org>

	* src/resource.c (make_resource_list): Renamed functions, was
	empty_resource_list. Updated all callers.
	(dont_free_live_resource): #if:ed out check of gc_final_p.

	* src/io_commands.c: Deleted old function do_io_read_file.

	* src/io.c: Deleted old backend code.
	(io_run): Check for OOP_ERROR. #if:ed out for now, as it is not
	defined in liboop-0.7. 

	* src/client.c (accept_service_handler): Deleted exception_handler
	attribute.
	(do_accept_service): Use the connection's exception handler for
	raising protocol error.
	(make_accept_service_handler): Deleted exception_handler argument. 

	* src/channel.c (send_channel_request_responses): Deleted
	connection argument. 
	(make_channel_request_response): Likewise.
	(channel_request_exception_handler): Deleted connection attribute. 
	(make_channel_request_exception_handler): Deleted connection
	argument. 

Niels Möller's avatar
Niels Möller committed
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
2001-09-26  Niels Mller  <nisse@ehand.com>

	* src/server_session.c (shell_request_handler,
	exec_request_handler): Defined as static objects using
	DEFINE_CHANNEL_REQUEST. Updated users.

	* src/io_commands.c (connect_simple_comand,
	connect_connection_command): New static commands, replacing
	make_simple_connect and make_connect_connection. Updated users.

	* src/client_x11.c (channel_open_x11): Define as a static object
	using DEFINE_CHANNEL_OPEN. Updated users.

	* src/channel.h (DEFINE_CHANNEL_OPEN): New macro.
	(DEFINE_CHANNEL_REQUEST): New macro.

	* src/zlib.c (zlib_deflate): Bugfix: Call deflateEnd, not
	inflateEnd, when deleting a deflate object. FIX copied from 1.2
	branch. 

	* src/sftp/xmalloc.c: Include string.h.

Niels Möller's avatar
Niels Möller committed
666
667
2001-09-25  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
668
669
670
671
672
673
674
675
676
677
	* src/gc.c (gc_register): Set gc_scheduled flag before creating
	the gc callout.

	* src/io.c (lsh_oop_time_callback): New function.
	(lsh_oop_register_callout): New function.
	(lsh_oop_cancel_callout): New function.
	(do_kill_callout): New function.
	(io_callout): Deleted delay argument, as delays are not currently
	implemented. 

Niels Möller's avatar
Niels Möller committed
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
	* src/lsh-writekey.c (lsh_writekey_options2private_file): Dup
	string before passing it to make_io_write_file_info.
	(lsh_writekey_options2public_file): Updated call to
	make_io_write_file_info. 

	* src/sexp.c (do_format_sexp_vector): Fixed string leak in
	pretty-printing code.

	* src/io_commands.c (make_io_write_file_info): Changed type of the
	NAME argument. Now a struct lsh_string *.

	* src/io.c (io_final): Call gc_final. That makes sure that all
	callbacks are cancelled. Updated callers to not use gc_final, only
	io_final. 

	* src/gc.c (gc_final): Always define gc_fianl, and kill the
	resources in the root set. Deallocation and checks for leaks is
	still done only when DEBUG_ALLOC is defined.

Niels Möller's avatar
Niels Möller committed
697
698
699
700
701
702
703
704
705
706
707
2001-09-24  Niels Mller  <nisse@cuckoo.hack.org>

	* src/xalloc.c (lsh_object_check): Better message on type error.
	(lsh_object_check_subtype): Likewise.

	* src/lsh-writekey.c (make_writekey): Chenged order of options and
	stdin arguments. Delay call of read_sexp.

	* src/command.c (gaba_apply): Assert that a value has been
	returned.

Niels Möller's avatar
Niels Möller committed
708
709
2001-09-24  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
710
711
712
713
714
715
716
717
718
	* src/scm/gaba.scm (process-expr): Handle empty parameter list.

	* src/io.c: Deleted class io_backend. Register signal handlers and
	files with gc_global() instead. Deleted all references to
	io_backend in the rest of the source files. Doesn't quite work yet.

	* src/gc.c (gc_global): New function.
	(root_set): New global variable.

Niels Möller's avatar
Niels Möller committed
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
	* Liboop code (without gc) seems to work now. Tagging as
	MILESTONE_LIBOOP_20010924. 

	* src/write_buffer.c (write_buffer_close): Call close_fd if buffer
	is empty. 

	* src/unix_interact.c (window_subscriber): Added attribute
	interact, which points to the corresponding unix_interact.
	(do_kill_window_subscriber): New function, which updates the
	number of subscribers and removes the SIGWINCH handler if there
	are no subscribers left.
	(unix_interact): Added attributes backend, winch_handler and
	nsubscribers. 
	(unix_window_change_subscribe): Keep track of number of
	subscribers, and install the signal handler if it is needed.
	(make_unix_interact): Don't install any signal handler yet.

	* src/lshd.c (main): Changed the behaviour of the --no-syslog
	option. Now --daemon --no-syslog puts the process into the
	background without the rest of the daemonic setup. These option
	names should be changed to something more correct, but it is used
	only be the testsuite.

	* src/io.c (lsh_oop_signal_callback): Better trace message.
	(lsh_oop_signal_callback): Return OOP_CONTINUE.
	(lsh_oop_fd_read_callback): Return OOP_CONTINUE.
	(lsh_oop_register_read_fd): Check want_read, so we don't try to
	register the callback twice.
	(lsh_oop_fd_write_callback): Fixed assertion.
	(lsh_oop_fd_write_callback): Return OOP_CONTINUE.
	(lsh_oop_register_write_fd): Check want_write, so we don't try to
	register the callback twice.
	(io_run): Print a trace message if/when oop_sys_run returns.
	(do_connect_callback): Improved trace messages.
	(io_connect): Initialize fd->write before calling
	lsh_oop_register_write_fd. 
	(io_listen): Initialize fd->read before calling
	lsh_oop_register_read_fd. 
	(close_fd): Call lsh_oop_cancel_read_fd and
	lsh_oop_cancel_write_fd before clearing the alive flag.

Niels Möller's avatar
Niels Möller committed
760
761
762
763
764
765
2001-09-23  Niels Mller  <nisse@cuckoo.hack.org>

	* src/io.c: Added trace messages to liboop-related functions.

	* src/write_buffer.c: Include io.h.

Niels Möller's avatar
Niels Möller committed
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
2001-09-21  Niels Mller  <nisse@ehand.com>

	* configure.in: Check for liboop.

	* src/io.c (make_io_backend): Call new function io_init().
	(lsh_oop_register_read_fd): Updated the want_read flag. Changed
	most functions to call this function instead of updating the flag
	directly. 
	(lsh_oop_cancel_read_fd): Likewise.
	(lsh_oop_register_write_fd): Analogous changes for the want_write flag.
	(lsh_oop_cancel_write_fd): Likewise.
	(do_exc_finish_read_handler): Use lsh_oop_register_read_fd and
	lsh_oop_cancel_read_fd.  

	* src/write_buffer.c (make_write_buffer): Added fd argument.
	(do_write): Call lsh_oop_register_write_fd when buffer gets
	non-empty. 

	* src/reaper.c (make_reaper): Adapted to new io_signal_handler
	behaviour. 
	* src/unix_interact.c (make_unix_interact): Likewise.

	* src/channel_forward.c (do_channel_forward_send_adjust): Use
	lsh_oop_register_read_fd. 
	* src/client_session.c (do_send_adjust): Likewise.
	(do_client_io): Likewise.
	* src/server_session.c (do_send_adjust): Likewise.

Niels Möller's avatar
Niels Möller committed
794
795
796
797
798
2001-09-19  Niels Mller  <nisse@ehand.com>

	* src/server_keyexchange.c (do_init_server_dh): Fixed bug in the
	PEER_SSH_DSS_KLUDGE workaround. FIX copied from 1.2 branch.

Niels Möller's avatar
Niels Möller committed
799
800
801
802
803
804
805
806
2001-09-18  Niels Mller  <nisse@ehand.com>

	* src/io.c (lsh_oop_cancel_signal): New function.
	(do_write_callback): Call FD_PREPARE.
	(close_fd): Call lsh_oop_cancel_fd.
	(close_fd_nicely): Likewise.
	(close_fd_read): Likewise.

Niels Möller's avatar
Niels Möller committed
807
808
809
810
811
812
813
814
815
2001-09-18  Niels Mller  <nisse@cuckoo.hack.org>

	* src/io.c (lsh_oop_glue): New class.
	(make_lsh_oop_glue): New function.
	(lsh_oop_signal_callback): New function.
	(lsh_oop_register_signal): New function.
	(lsh_oop_fd_callback): New function.
	(lsh_oop_register_fd): New function.

Niels Möller's avatar
Niels Möller committed
816
817
818
819
2001-09-17  Niels Mller  <nisse@ehand.com>

	* src/io.c: Started experimental conversion to use liboop.

Niels Möller's avatar
Niels Möller committed
820
821
2001-09-16  Niels Mller  <nisse@cuckoo.hack.org>

Niels Möller's avatar
Niels Möller committed
822
823
	* doc/lsh.texinfo: Moved table of contents first.

Niels Möller's avatar
Niels Möller committed
824
825
826
	* src/dsa.c (do_dsa_sign): Display any unexpected algorithm atom
	before crashing.

Niels Möller's avatar
Niels Möller committed
827
828
829
830
831
832
833
834
835
836
2001-09-13  Niels Mller  <nisse@ehand.com>

	* src/io.c (address_info2sockaddr): Fixed debug invocation. FIX
	copied from 1.2 branch.

2001-09-12  Niels Mller  <nisse@ehand.com>

	* src/werror.c (werror_vformat): Don't crash if %a gets a zero
	argument. FIXED in 1.2 branch.

Niels Möller's avatar
Niels Möller committed
837
838
839
840
841
2001-09-09  Niels Mller  <nisse@cuckoo.hack.org>

	* src/des.c (make_des_instance): Use the des_fix_parity function
	in nettle.

Niels Möller's avatar
Niels Möller committed
842
843
844
845
846
847
848
849
850
851
852
853
2001-09-05  Niels Mller  <nisse@ehand.com>

	* src/crypto.h: Deleted last traces of idea support.
	* src/atoms.in: Likewise.
	* src/algorithms.c: Likewise.
	* src/Makefile.am.in: Likewise.

	* src/testsuite/lsh-6-test: New test, exercising the various -c
	options. 

	* configure.in: Bumped version to 1.3.5.

Niels Möller's avatar
Niels Möller committed
854
855
856
857
2001-09-04  Niels Mller  <nisse@cuckoo.hack.org>

	* Released lsh-1.3.4.

Niels Möller's avatar
Niels Möller committed
858
859
860
861
862
863
864
865
866
867
2001-09-04  Niels Mller  <nisse@ehand.com>

	* doc/lsh.texinfo: Updated for 1.3.4. In particular, added doc on
	X forwarding, -x, -B, and --log-file options, and encrypted
	private keys. Deleted the paragraph about the obsolete --userauth
	option. 

	* src/client.c (client_command_session): Ask for a pty also for
	(supposedly non-interactive) exec sessions.

Niels Möller's avatar
Niels Möller committed
868
869
870
871
872
873
874
875
876
877
878
879
880
2001-09-03  Niels Mller  <nisse@cuckoo.hack.org>

	* src/xauth.c (xauth_process): New function, using XauReadAuth.
	(xauth_lookup): Use xauth_process instead of XauGetAuthByAddr.

	* src/client_x11.c (make_client_x11_display): Initialize the fake
	cookie properly.

	* src/xauth.h: New file with the xauth_lookup prototype.

	* src/xauth.c (xauth_lookup): Deleted address_length argument. Bug
	fixes. 

Niels Möller's avatar
Niels Möller committed
881
882
2001-09-03  Niels Mller  <nisse@ehand.com>

Niels Möller's avatar
Niels Möller committed
883
884
885
886
887
888
889
890
891
892
893
894
895
	* src/xauth.c: Rewrote to use libXau.

	* src/client_x11.c (client_x11_auth_info): Deleted class; merged
	with client_x11_display.
	(parse_display): Take a client_x11_display as argument. Do xauth lookup.
	(get_client_x11_auth_info): Deleted function.

	* src/client.c (DEFINE_CALLBACK): Declare self argument as UNUSED.

	* src/Makefile.am.in (liblsh_a_SOURCES): Added xauth.c.

	* configure.in: Check for X, libXau and XauGetAuthByAddr.

Niels Möller's avatar
Niels Möller committed
896
897
898
899
900
901
902
903
904
	* src/client_x11.c (client_x11_channel): New fields auth_length
	and name_length, for recording the decoded lengths in the setup
	message.  
	(X11_SETUP_MAX_LENGTH): Defined as 48, which is the size of a message
	with a 16 octet cookie.
	Updated description of the X11 connection setup message.
	(LE_READ_UINT16, LE_WRITE_UINT16): New macros. 
	(do_client_channel_x11_receive): Bug fixes, seems to work now.

Niels Möller's avatar
Niels Möller committed
905
906
907
	* src/suspend.h: Declare suspend_callback as extern. Noticed by
	Jean-Pierre. 

Niels Möller's avatar
Niels Möller committed
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
2001-09-03  Niels Mller  <nisse@cuckoo.hack.org>

	* src/client_x11.c: Added comment about observed X11 packets (that
	seem contrary to the documentation in RFC 1013.
	(do_client_channel_x11_receive): Print received cookie, for
	debugging purposes.
	(make_forward_x11): Print generated fake cookie, for debugging
	purposes. 
	(parse_display): Fixed ssh_format invocation creating the local
	socket name.
	(do_channel_open_x11): Fixed invocation of verbose().
	(do_format_request_x11_forward): Get the connection from the
	channel, now that the connection pointer is available there.
	(do_format_request_x11_forward): Hex encode the cookie. That's
	ugly, but needed for compatibility.

	* src/client_pty.c: Dropped lsh:-prefix on messages, it's added
	automatically in werror.c.

	* src/client.c (client_maybe_x11): Write a message if DISPLAY not
	set or it's value doesn't make sense.

Niels Möller's avatar
Niels Möller committed
930
931
2001-09-02  Niels Mller  <nisse@cuckoo.hack.org>

Niels Möller's avatar
Niels Möller committed
932
933
934
935
936
	* src/client.c (make_client_session): Added escape sequences q, v
	and d, for controlling the verbosity flags.
	(client_argp_parser): Look at used_x11 after setting up the shell
	session. 

Niels Möller's avatar
Niels Möller committed
937
938
939
940
941
942
943
944
945
946
947
948
949
	* src/lshg.c (make_options): Pass NULL random to
	init_client_options. 

	* src/client_x11.c (make_client_x11_display): Free the fake cookie
	if we fail.
	(make_forward_x11): Make up a random cookie.

	* src/client.c (init_client_options): New argument RANDOM.
	(client_maybe_x11): Pass on RANDOM to make_forward_x11.

	* src/client.h (client_options): Moved RANDOM attribute here, from
	lsh_options. 

Niels Möller's avatar
Niels Möller committed
950
951
2001-09-01  Niels Mller  <nisse@cuckoo.hack.org>

Niels Möller's avatar
Niels Möller committed
952
953
954
955
956
957
958
959
960
	* src/client.c: Moved -x option to lsh.c.

	* src/channel.c (register_channel): Deleted connection argument.

	* src/channel.h (ssh_channel): Replaced the write pointer with a
	pointer to the connection.
	(channel_request): Deleted connection argument.
	* src/channel.h (CHANNEL_REQUEST): Likewise.

Niels Möller's avatar
Niels Möller committed
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
	* src/resource.c (init_resource): Renamed from resource_init, for
	consistency. Updated all callers.

	* src/lsh.h (struct client_x11_display): Forward declare.

	* src/client_x11.h: Deleted, prototypes moved to client.h.

	* src/client.h (client_options): New attributes with_x11 and
	used_x11.

	* src/client.c (client_maybe_pty): New function.
	(client_maybe_x11): New function.
	(client_shell_session): Use client_maybe_pty and client_maybe_x11.
	(client_command_session): Use client_maybe_x11.
	(client_argp_parser): --x11-forward should be a modifier option,
	not an action.

	* src/channel.h (channel_table): Added attribute x11_display.

	* src/Makefile.am.in (liblsh_a_SOURCES): Added client_x11.c.

Niels Möller's avatar
Niels Möller committed
982
983
984
985
2001-08-31  Niels Mller  <nisse@ehand.com>

	* src/client.c (client_argp_parser): Implemented -X flag.

Niels Möller's avatar
Niels Möller committed
986
987
988
989
990
991
992
993
994
995
2001-08-30  Niels Mller  <nisse@cuckoo.hack.org>

	* src/xauth.c: New file.

	* src/client_x11.c: Work in progress.
	(client_x11_auth_info): New class.

	* src/channel_forward.c (init_channel_forward): New function,
	extracted from make_channel_forward.

Niels Möller's avatar
Niels Möller committed
996
997
998
999
2001-08-30  Niels Mller  <nisse@ehand.com>

	* configure.in: Bumped version to 1.3.4.

Niels Möller's avatar
Niels Möller committed
1000
2001-08-29  Niels Mller  <nisse@cuckoo.hack.org>