From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Thu, 17 Aug 1995 03:13:25 -0400 From: Vadim Antonov avg@postman.ncube.com Subject: FTPD plaintext password option Topicbox-Message-UUID: 17b7aeb6-eac8-11e9-9e20-41e7f4b1d025 Message-ID: <19950817071325.SgWh0PYhHZYk7KLcJz9_AnbuM18n2qUa6PdSGi1tK1k@z> Few changes, to provide the same functionality as -P in telnetd. --vadim cpu% pwd /sys/src/cmd/service cpu% diff ftp.c.old ftp.c 125a126 > int plaintext; 169a171,173 > case 'P': > plaintext = 1; > break; 471c475,476 < return reply("331 encrpyt challenge, %s, as a password", ch.chal); --- > return reply(plaintext? "331 Your password, please?" : > "331 Encrypt challenge, %s, as a password", ch.chal); 479a485,486 > char key[DESKEYLEN]; > 485c492,497 < return reply("531 Send user id before encrypted challenge"); --- > return reply("531 Send user id before password"); > if(plaintext) { > passtokey(key, response); > strcpy(response, ch.chal); > netcrypt(key, response); > } cpu%