add ftppass_hostnamegen
This commit is contained in:
@@ -1,3 +1,10 @@
|
|||||||
|
2001-11-24 Fumitoshi UKAI <ukai@debian.or.jp
|
||||||
|
|
||||||
|
* fm.h (ftppass_hostnamegen): runtime option ftppass_hostnamegen
|
||||||
|
* ftp.c (FtpLogin): ditto
|
||||||
|
* rc.c (CMT_FTPPASS_HOSTNAMEGEN): ditto
|
||||||
|
* rc.c (params9): ditto
|
||||||
|
|
||||||
2001-11-24 Akihiro Sagawa <sagawa@sohgoh.net>
|
2001-11-24 Akihiro Sagawa <sagawa@sohgoh.net>
|
||||||
|
|
||||||
* [w3m-dev 02528] RFC2732 URL Patch
|
* [w3m-dev 02528] RFC2732 URL Patch
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
/* $Id: fm.h,v 1.12 2001/11/23 19:00:47 ukai Exp $ */
|
/* $Id: fm.h,v 1.13 2001/11/23 20:23:41 ukai Exp $ */
|
||||||
/*
|
/*
|
||||||
* w3m: WWW wo Miru utility
|
* w3m: WWW wo Miru utility
|
||||||
*
|
*
|
||||||
@@ -713,6 +713,9 @@ global char *ExtBrowser2 init(NULL);
|
|||||||
global char *ExtBrowser3 init(NULL);
|
global char *ExtBrowser3 init(NULL);
|
||||||
global int BackgroundExtViewer init(TRUE);
|
global int BackgroundExtViewer init(TRUE);
|
||||||
global char *ftppasswd init(NULL);
|
global char *ftppasswd init(NULL);
|
||||||
|
#ifdef FTPPASS_HOSTNAMEGEN
|
||||||
|
global int ftppass_hostnamegen init(TRUE);
|
||||||
|
#endif
|
||||||
global int do_download init(FALSE);
|
global int do_download init(FALSE);
|
||||||
global char *UserAgent init(NULL);
|
global char *UserAgent init(NULL);
|
||||||
global int NoSendReferer init(FALSE);
|
global int NoSendReferer init(FALSE);
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
/* $Id: ftp.c,v 1.4 2001/11/20 17:49:23 ukai Exp $ */
|
/* $Id: ftp.c,v 1.5 2001/11/23 20:23:41 ukai Exp $ */
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
#include <Str.h>
|
#include <Str.h>
|
||||||
@@ -110,7 +110,7 @@ FtpLogin(FTP * ftp_return, char *host, char *user, char *pass)
|
|||||||
if (fd < 0)
|
if (fd < 0)
|
||||||
return -1;
|
return -1;
|
||||||
#ifdef FTPPASS_HOSTNAMEGEN
|
#ifdef FTPPASS_HOSTNAMEGEN
|
||||||
if (!strcmp(user, "anonymous")) {
|
if (ftppass_hostnamegen && !strcmp(user, "anonymous")) {
|
||||||
size_t n = strlen(pass);
|
size_t n = strlen(pass);
|
||||||
|
|
||||||
if (n > 0 && pass[n - 1] == '@') {
|
if (n > 0 && pass[n - 1] == '@') {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
/* $Id: rc.c,v 1.7 2001/11/21 19:24:35 ukai Exp $ */
|
/* $Id: rc.c,v 1.8 2001/11/23 20:23:41 ukai Exp $ */
|
||||||
/*
|
/*
|
||||||
* Initialization file etc.
|
* Initialization file etc.
|
||||||
*/
|
*/
|
||||||
@@ -98,6 +98,9 @@ static int rc_initialized = 0;
|
|||||||
#define CMT_EXTBRZ2 "外部ブラウザその2"
|
#define CMT_EXTBRZ2 "外部ブラウザその2"
|
||||||
#define CMT_EXTBRZ3 "外部ブラウザその3"
|
#define CMT_EXTBRZ3 "外部ブラウザその3"
|
||||||
#define CMT_FTPPASS "FTPのパスワード(普通は自分のmail addressを使う)"
|
#define CMT_FTPPASS "FTPのパスワード(普通は自分のmail addressを使う)"
|
||||||
|
#ifdef FTPPASS_HOSTNAMEGEN
|
||||||
|
#define CMT_FTPPASS_HOSTNAMEGEN "FTPのパスワードのドメイン名を自動生成する"
|
||||||
|
#endif
|
||||||
#define CMT_USERAGENT "User-Agent"
|
#define CMT_USERAGENT "User-Agent"
|
||||||
#define CMT_ACCEPTLANG "受けつける言語(Accept-Language:)"
|
#define CMT_ACCEPTLANG "受けつける言語(Accept-Language:)"
|
||||||
#define CMT_DOCUMENTCODE "文書の文字コード"
|
#define CMT_DOCUMENTCODE "文書の文字コード"
|
||||||
@@ -193,6 +196,9 @@ static int rc_initialized = 0;
|
|||||||
#define CMT_EXTBRZ2 "Second External Browser"
|
#define CMT_EXTBRZ2 "Second External Browser"
|
||||||
#define CMT_EXTBRZ3 "Third External Browser"
|
#define CMT_EXTBRZ3 "Third External Browser"
|
||||||
#define CMT_FTPPASS "Password for FTP(use your mail address)"
|
#define CMT_FTPPASS "Password for FTP(use your mail address)"
|
||||||
|
#ifdef FTPPASS_HOSTNAMEGEN
|
||||||
|
#define CMT_FTPPASS_HOSTNAMEGEN "generate domain part of password for FTP"
|
||||||
|
#endif
|
||||||
#define CMT_USERAGENT "User-Agent"
|
#define CMT_USERAGENT "User-Agent"
|
||||||
#define CMT_ACCEPTLANG "Accept-Language"
|
#define CMT_ACCEPTLANG "Accept-Language"
|
||||||
/* #define CMT_DOCUMENTCODE "Document Charset" */
|
/* #define CMT_DOCUMENTCODE "Document Charset" */
|
||||||
@@ -456,6 +462,9 @@ struct param_ptr params8[] =
|
|||||||
struct param_ptr params9[] =
|
struct param_ptr params9[] =
|
||||||
{
|
{
|
||||||
{"ftppasswd", P_STRING, PI_TEXT, (void *) &ftppasswd, CMT_FTPPASS, NULL},
|
{"ftppasswd", P_STRING, PI_TEXT, (void *) &ftppasswd, CMT_FTPPASS, NULL},
|
||||||
|
#ifdef FTPPASS_HOSTNAMEGEN
|
||||||
|
{"ftppass_hostnamegen", P_INT, PI_ONOFF, (void *) &ftppass_hostnamegen, CMT_FTPPASS_HOSTNAMEGEN, NULL},
|
||||||
|
#endif
|
||||||
{"user_agent", P_STRING, PI_TEXT, (void *) &UserAgent, CMT_USERAGENT, NULL},
|
{"user_agent", P_STRING, PI_TEXT, (void *) &UserAgent, CMT_USERAGENT, NULL},
|
||||||
{"no_referer", P_INT, PI_ONOFF, (void *) &NoSendReferer, CMT_NOSENDREFERER, NULL},
|
{"no_referer", P_INT, PI_ONOFF, (void *) &NoSendReferer, CMT_NOSENDREFERER, NULL},
|
||||||
{"accept_language", P_STRING, PI_TEXT, (void *) &AcceptLang, CMT_ACCEPTLANG, NULL},
|
{"accept_language", P_STRING, PI_TEXT, (void *) &AcceptLang, CMT_ACCEPTLANG, NULL},
|
||||||
|
|||||||
Reference in New Issue
Block a user