Date: Tue, 18 Nov 1997 12:02:57 +0800 (CST) From: yssu@CCCA.NCTU.edu.tw To: FreeBSD-gnats-submit@FreeBSD.ORG, yssu@CCCA.NCTU.edu.tw Subject: ports/5076: New Import Message-ID: <199711180402.MAA13921@netflow.nctu.edu.tw> Resent-Message-ID: <199711180410.UAA15274@hub.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 5076 >Category: ports >Synopsis: New port commit in chinese cat. >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Class: support >Submitter-Id: current-users >Arrival-Date: Mon Nov 17 20:10:01 PST 1997 >Last-Modified: >Originator: Yen-Shuo Su >Organization: Campus Computer Communication Association >Release: FreeBSD 2.2-970625-RELENG i386 >Environment: CPU: AMD K5 PR166 (116.93-MHz 586-class CPU) >Description: New port imported from chinese/samba and net/samba-des to chinese/samba-des >How-To-Repeat: N/A >Fix: The new port diff file: diff -ruN samba-des.orig/Makefile samba-des/Makefile --- samba-des.orig/Makefile Thu Jan 1 08:00:00 1970 +++ samba-des/Makefile Tue Nov 18 11:33:11 1997 @@ -0,0 +1,78 @@ +# New ports collection makefile for: samba-des +# Version required: 1.9.17p4 +# Date created: 18 Nov 1997 +# Whom: Yen-Shuo Su <yssu@CCCA.NCTU.edu.tw> +# +# $Id$ +# + +DISTNAME= samba-1.9.17p4 +PKGNAME= zh-samba-des-1.9.17.4 +CATEGORIES= chinese net +MASTER_SITES= ftp://samba.anu.edu.au/pub/samba/ \ + ftp://samba.anu.edu.au/pub/libdes/ +DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \ + libdes-3.23.tar.gz + +MAINTAINER= yssu@CCCA.NCTU.edu.tw + +RESTRICTED= "Crypto; export-controlled" + +NO_WRKSUBDIR= yes +MAN1= smbstatus.1 smbclient.1 smbrun.1 smbtar.1 testparm.1 testprns.1 +MAN5= smb.conf.5 +MAN7= samba.7 +MAN8= smbd.8 nmbd.8 smbpasswd.8 + +STARTUP_SCRIPT= ${PREFIX}/etc/rc.d/samba.sh.sample +SAMPLE_CONFIG= ${PREFIX}/etc/smb.conf.sample +SAMBA_SPOOL= /var/spool/samba +XSAMBA_SPOOL= \/var\/spool\/samba +SAMBA_LOGDIR= /var/log +XSAMBA_LOGDIR= \/var\/log +SAMBA_PRIVATE= ${PREFIX}/private + +post-install: +.if !defined(NOPORTDOCS) + ${MKDIR} ${PREFIX}/share/doc/samba/faq + for i in ${WRKDIR}/${DISTNAME}/docs/*.txt ${WRKDIR}/${DISTNAME}/docs/README* ; do \ + ${INSTALL_DATA} $$i ${PREFIX}/share/doc/samba ; \ + done + for i in ${WRKDIR}/${DISTNAME}/docs/faq/* ; do \ + ${INSTALL_DATA} $$i ${PREFIX}/share/doc/samba/faq ; \ + done +.endif + @if [ ! -f ${STARTUP_SCRIPT} ]; then \ + ${ECHO} "Installing ${STARTUP_SCRIPT} startup file." ; \ + ${ECHO} '#!/bin/sh' > ${STARTUP_SCRIPT} ; \ + ${ECHO} 'smbd=${PREFIX}/sbin/smbd' >> ${STARTUP_SCRIPT} ;\ + ${ECHO} 'nmbd=${PREFIX}/sbin/nmbd' >> ${STARTUP_SCRIPT} ;\ + ${ECHO} 'if [ -f $$smbd ]; then' >> ${STARTUP_SCRIPT} ; \ + ${ECHO} " ${ECHO} -n ' Samba'" >> ${STARTUP_SCRIPT} ;\ + ${ECHO} ' $$smbd -D' >> ${STARTUP_SCRIPT} ; \ + ${ECHO} ' $$nmbd -D' >> ${STARTUP_SCRIPT} ; \ + ${ECHO} "fi" >> ${STARTUP_SCRIPT} ; \ + chmod 755 ${STARTUP_SCRIPT} ; \ + chown bin.bin ${STARTUP_SCRIPT}; \ + fi + @test -d ${SAMBA_SPOOL} || ${MKDIR} ${SAMBA_SPOOL} && chmod 1777 ${SAMBA_SPOOL} + @if [ ! -f ${SAMPLE_CONFIG} ]; then \ + ${SED} -e 's/__SAMBA_SPOOL__/${XSAMBA_SPOOL}/' \ + -e 's/__LOGDIR__/${XSAMBA_LOGDIR}/' \ + ${FILESDIR}/smb.conf.sample \ + > ${SAMPLE_CONFIG} ; \ + fi + ${INSTALL} -c -m 755 -o bin -g bin ${WRKSRC}/${DISTNAME}/source/mksmbpasswd.sh ${PREFIX}/bin + if [ ! -d ${SAMBA_PRIVATE} ] ; then \ + ${MKDIR} ${SAMBA_PRIVATE} ; \ + chown root.wheel ${SAMBA_PRIVATE} ; \ + chmod 700 ${SAMBA_PRIVATE} ; \ + fi + if [ ! -f ${SAMBA_PRIVATE}/smbpasswd ] ; then \ + ${CAT} /etc/passwd | ${PREFIX}/bin/mksmbpasswd.sh > ${SAMBA_PRIVATE}/smbpasswd ; \ + chmod 600 ${SAMBA_PRIVATE}/smbpasswd ; \ + fi + chown root.wheel ${PREFIX}/bin/smbpasswd + chmod 4111 ${PREFIX}/bin/smbpasswd + +.include <bsd.port.mk> diff -ruN samba-des.orig/files/md5 samba-des/files/md5 --- samba-des.orig/files/md5 Thu Jan 1 08:00:00 1970 +++ samba-des/files/md5 Tue Nov 18 11:07:14 1997 @@ -0,0 +1,2 @@ +MD5 (samba-1.9.17p4.tar.gz) = dd8a65242a2bb969a9a5f3d7095df602 +MD5 (libdes-3.23.tar.gz) = 0645f262b1729757ca66075af42d53b8 diff -ruN samba-des.orig/files/smb.conf.sample samba-des/files/smb.conf.sample --- samba-des.orig/files/smb.conf.sample Thu Jan 1 08:00:00 1970 +++ samba-des/files/smb.conf.sample Tue Nov 18 11:07:14 1997 @@ -0,0 +1,182 @@ +; Configuration file for smbd. +; ============================================================================ +; For the format of this file and comprehensive descriptions of all the +; configuration option, please refer to the man page for smb.conf(5). +; +; The following configuration should suit most systems for basic usage and +; initial testing. It gives all clients access to their home directories and +; allows access to all printers specified in /etc/printcap. +; +; Things you need to check: +; -------------------------- +; +; 1: Check the path to your printcap file. If you are using a system that does +; not use printcap (eg., Solaris), create a file containing lines of the +; form +; +; printername|printername|printername| +; +; where each "printername" is the name of a printer you want to provide +; access to. Then alter the "printcap =" entry to point to the new file. +; +; If using Solaris, the following command will generate a suitable printcap +; file: +; +; lpc status | grep ":" | sed s/:/\|/ > myprintcap +; +; 2: Make sure the "print command" entry is correct for your system. This +; command should submit a file (represented by %s) to a printer +; (represented by %p) for printing and should REMOVE the file after +; printing. +; +; One most systems the default will be OK, as long as you get "printing =" +; right. +; +; It is also a good idea to use an absolute path in the print command +; as there is no guarantee the search path will be set correctly. +; +; 3: Make sure the "printing =" option is set correctly for your system. +; Possible values are "sysv", "bsd" or "aix". +; +; 4: Make sure the "lpq command" entry is correct for your system. The default +; may not work for you. +; +; 5: Make sure that the user specified in "guest account" exists. Typically +; this will be a user that cannot log in and has minimal privileges. +; Often the "nobody" account doesn't work (very system dependant). +; +; 6: You should consider the "security =" option. See a full description +; in the main documentation and the smb.conf(5) manual page +; +; 7: Look at the "hosts allow" option, unless you want everyone on the internet +; to be able to access your files. +; +[global] + comment = FreeBSD - Samba %v + workgroup = WORKGROUP + printing = bsd + printcap name = /etc/printcap + load printers = yes + guest account = nobody +; This next option sets a separate log file for each client. Remove +; it if you want a combined log file. + log file = __LOGDIR__/sambalog.%m + dont descend = /dev,/proc,/root,/stand + +; You will need a world readable lock directory and "share modes=yes" +; if you want to support the file sharing modes for multiple users +; of the same files +; lock directory = /usr/local/samba/var/locks +; share modes = yes + + map archive = no + status = yes + public = yes + read only = no + preserve case = yes + strip dot = yes + security = user + encrypt passwords = yes + guest ok = no + coding system = cap + +[homes] + comment = Home Directories + browseable = no + read only = no + create mode = 0750 + +[printers] + comment = All Printers + path = __SAMBA_SPOOL__ + browseable = no + printable = yes + public = no + writable = no + create mode = 0700 + +; you might also want this one, notice that it is read only so as not to give +; people without an account write access. +; +; [tmp] +; comment = Temporary file space +; path = /tmp +; read only = yes +; public = yes + +; +; Other examples. +; +; A private printer, usable only by fred. Spool data will be placed in fred's +; home directory. Note that fred must have write access to the spool directory, +; wherever it is. +;[fredsprn] +; comment = Fred's Printer +; valid users = fred +; path = /homes/fred +; printer = freds_printer +; public = no +; writable = no +; printable = yes +; +; A private directory, usable only by fred. Note that fred requires write +; access to the directory. +;[fredsdir] +; comment = Fred's Service +; path = /usr/somewhere/private +; valid users = fred +; public = no +; writable = yes +; printable = no +; +; A publicly accessible directory, but read only, except for people in +; the staff group +;[public] +; comment = Public Stuff +; path = /usr/somewhere/public +; public = yes +; writable = no +; printable = no +; write list = @staff +; +; a service which has a different directory for each machine that connects +; this allows you to tailor configurations to incoming machines. You could +; also use the %u option to tailor it by user name. +; The %m gets replaced with the machine name that is connecting. +;[pchome] +; comment = PC Directories +; path = /usr/pc/%m +; public = no +; writeable = yes +; +; +; A publicly accessible directory, read/write to all users. Note that all files +; created in the directory by users will be owned by the default user, so +; any user with access can delete any other user's files. Obviously this +; directory must be writable by the default user. Another user could of course +; be specified, in which case all files would be owned by that user instead. +;[public] +; path = /usr/somewhere/else/public +; public = yes +; only guest = yes +; writable = yes +; printable = no +; +; +; The following two entries demonstrate how to share a directory so that two +; users can place files there that will be owned by the specific users. In this +; setup, the directory should be writable by both users and should have the +; sticky bit set on it to prevent abuse. Obviously this could be extended to +; as many users as required. +;[myshare] +; comment = Mary's and Fred's stuff +; path = /usr/somewhere/shared +; valid users = mary fred +; public = no +; writable = yes +; printable = no +; create mask = 0765 + + + + diff -ruN samba-des.orig/patches/patch-aa samba-des/patches/patch-aa --- samba-des.orig/patches/patch-aa Thu Jan 1 08:00:00 1970 +++ samba-des/patches/patch-aa Tue Nov 18 11:08:13 1997 @@ -0,0 +1,85 @@ +--- samba-1.9.17p4/source/Makefile.orig Sat Sep 27 00:04:52 1997 ++++ samba-1.9.17p4/source/Makefile Wed Oct 15 17:48:21 1997 +@@ -5,11 +5,11 @@ + ########################################################################### + + # The base directory for all samba files +-BASEDIR = /usr/local/samba ++BASEDIR = $(PREFIX) + + # The base manpages directory to put the man pages in + # Note: $(MANDIR)/man1, $(MANDIR)/man5 and $(MANDIR)/man8 must exist. +-MANDIR = /usr/local/man ++MANDIR = $(PREFIX)/man + + # The directories to put things in. If you use multiple + # architectures or share the samba binaries across NFS then +@@ -18,9 +18,9 @@ + # normally only applies to nmbd and smbd + # SBINDIR implies a secure binary directory + BINDIR = $(BASEDIR)/bin +-SBINDIR = $(BASEDIR)/bin +-LIBDIR = $(BASEDIR)/lib +-VARDIR = $(BASEDIR)/var ++SBINDIR = $(BASEDIR)/sbin ++ETCDIR = $(BASEDIR)/etc ++LOGDIR = /var/log + + # The permissions to give the executables + INSTALLPERMS = 0755 +@@ -45,13 +45,13 @@ + # set these to where to find various files + # These can be overridden by command line switches (see smbd(8)) + # or in smb.conf (see smb.conf(5)) +-SMBLOGFILE = $(VARDIR)/log.smb +-NMBLOGFILE = $(VARDIR)/log.nmb +-CONFIGFILE = $(LIBDIR)/smb.conf +-LMHOSTSFILE = $(LIBDIR)/lmhosts ++SMBLOGFILE = $(LOGDIR)/smb ++NMBLOGFILE = $(LOGDIR)/nmb ++CONFIGFILE = $(ETCDIR)/smb.conf ++LMHOSTSFILE = $(ETCDIR)/lmhosts + + # the directory where lock files go +-LOCKDIR = $(VARDIR)/locks ++LOCKDIR = /var/spool/lock + + # set this to the default group you want your machine to appear in + # for browsing. This can also be set in nmbd (see nmbd(8)) +@@ -111,10 +111,10 @@ + # This is for SMB encrypted (lanman) passwords. + # you may wish to add -DREPLACE_GETPASS if your getpass() is limited + # to 8 chars +-# DES_BASE=/usr/local/libdes +-# DES_FLAGS= -I$(DES_BASE) +-# DES_LIB= -L$(DES_BASE) -ldes +-# PASSWD_FLAGS=-DUSE_LIBDES -DSMB_PASSWD=\"$(BINDIR)/smbpasswd\" -DSMB_PASSWD_FILE=\"$(BASEDIR)/private/smbpasswd\" ++DES_BASE=../../ ++DES_FLAGS= -I$(DES_BASE) ++DES_LIB= -L$(DES_BASE) -ldes ++PASSWD_FLAGS=-DUSE_LIBDES -DSMB_PASSWD=\"$(BINDIR)/smbpasswd\" -DSMB_PASSWD_FILE=\"$(BASEDIR)/private/smbpasswd\" + + ###################################### + # VTP-Support +@@ -383,8 +383,8 @@ + # This is for FreeBSD + # contributed by kuku@acds.physik.rwth-aachen.de + # NOTE: You may need to add -DBSD44 if you have password problems +-# FLAGSM = -DFreeBSD -DFAST_SHARE_MODES +-# LIBSM = -lcrypt ++FLAGSM = -DFreeBSD -DFAST_SHARE_MODES -DBIG5 ++LIBSM = -lcrypt + + + # This is for NEXTSTEP Release 2.X +@@ -684,8 +684,8 @@ + install: installbin installman installscripts + + installbin: all +- @$(SHELL) $(srcdir)installbin.sh $(INSTALLPERMS) $(BASEDIR) $(SBINDIR) $(LIBDIR) $(VARDIR) $(SPROGS) +- @$(SHELL) $(srcdir)installbin.sh $(INSTALLPERMS) $(BASEDIR) $(BINDIR) $(LIBDIR) $(VARDIR) $(PROGS) ++ @$(SHELL) $(srcdir)installbin.sh $(INSTALLPERMS) $(BASEDIR) $(SBINDIR) $(ETCDIR) $(LOGDIR) $(SPROGS) ++ @$(SHELL) $(srcdir)installbin.sh $(INSTALLPERMS) $(BASEDIR) $(BINDIR) $(ETCDIR) $(LOGDIR) $(PROGS) + + installscripts: + @$(SHELL) $(srcdir)installscripts.sh $(INSTALLPERMS) $(BINDIR) $(SCRIPTS) diff -ruN samba-des.orig/patches/patch-ab samba-des/patches/patch-ab --- samba-des.orig/patches/patch-ab Thu Jan 1 08:00:00 1970 +++ samba-des/patches/patch-ab Tue Nov 18 11:07:14 1997 @@ -0,0 +1,30 @@ +--- Makefile.orig Fri Apr 12 09:18:51 1996 ++++ Makefile Thu Aug 14 00:49:39 1997 +@@ -10,7 +10,7 @@ + # If you are on a DEC Alpha, edit des.h and change the DES_LONG + # define to 'unsigned int'. I have seen this give a %20 speedup. + +-OPTS0= -DRAND -DTERMIO #-DNOCONST ++OPTS0= -DRAND -DSGTTY #-DNOCONST + + # Version 1.94 has changed the strings_to_key function so that it is + # now compatible with MITs when the string is longer than 8 characters. +@@ -72,7 +72,12 @@ + + DLIB= libdes.a + +-all: $(DLIB) destest rpw des speed ++all: xall ++ (cd samba-1.9.17p4/source && make all) ++install: ++ (cd samba-1.9.17p4/source && make install) ++ ++xall: $(DLIB) destest rpw des speed + + test: all + ./destest +@@ -152,4 +157,3 @@ + cp des.h $(INCDIR)/des.h; \ + chmod 644 $(INCDIR)/des.h; \ + fi +-# DO NOT DELETE THIS LINE -- make depend depends on it. diff -ruN samba-des.orig/patches/patch-ac samba-des/patches/patch-ac --- samba-des.orig/patches/patch-ac Thu Jan 1 08:00:00 1970 +++ samba-des/patches/patch-ac Tue Nov 18 11:37:59 1997 @@ -0,0 +1,394 @@ +--- samba-1.9.17p4/source/client.c.orig Sat Sep 6 05:52:12 1997 ++++ samba-1.9.17p4/source/client.c Fri Oct 3 00:12:33 1997 +@@ -3040,8 +3040,10 @@ + /* send a session request (RFC 8002) */ + + strcpy(dest,desthost); ++#ifndef BIG5 + p = strchr(dest,'.'); + if (p) *p = 0; ++#endif + + /* put in the destination name */ + p = outbuf+len; +--- samba-1.9.17p4/source/clitar.c.orig Sat Sep 6 04:53:47 1997 ++++ samba-1.9.17p4/source/clitar.c Fri Oct 3 00:12:34 1997 +@@ -325,7 +325,20 @@ + } + } + #else ++#ifdef BIG5 ++ while (l > 0) { ++ if (is_shift_big5 (*fp)) { ++ *tptr++ = *fp++; ++ *tptr++ = *fp++; ++ l -= 2; ++ } else { ++ *tptr++ = *fp++; ++ l--; ++ } ++ } ++#else + while (l--) { *tptr=(*fp == '\\') ? '/' : *fp; tptr++; fp++; } ++#endif /* BIG5 */ + #endif + } + +@@ -1222,7 +1235,20 @@ + } + } + #else ++#ifdef BIG5 ++ while (l > 0) { ++ if (is_shift_big5 (*fp)) { ++ *tptr++ = *fp++; ++ *tptr++ = *fp++; ++ l -= 2; ++ } else { ++ *tptr++ = *fp++; ++ l--; ++ } ++ } ++#else + while (l--) { *tptr=(*fp == '/') ? '\\' : *fp; tptr++; fp++; } ++#endif /* BIG5 */ + #endif + } + +--- samba-1.9.17p4/source/kanji.h.orig Fri Aug 22 12:35:21 1997 ++++ samba-1.9.17p4/source/kanji.h Fri Oct 3 00:12:34 1997 +@@ -145,3 +145,8 @@ + #endif /* not KANJI */ + + #endif /* _KANJI_H_ */ ++ ++#ifdef BIG5 ++#define is_shift_big5(c) \ ++ (0x80 <= ((unsigned char) (c))) ++#endif +--- samba-1.9.17p4/source/mangle.c.orig Fri Sep 26 20:44:19 1997 ++++ samba-1.9.17p4/source/mangle.c Fri Oct 3 00:12:34 1997 +@@ -140,12 +140,28 @@ + } + } + #else ++#ifdef BIG5 ++ dot_pos = 0; ++ while (*p) ++ { ++ if (is_shift_big5 (*p)) { ++ p += 2; ++ } else { ++ if (*p == '.' && !dot_pos) ++ dot_pos = (char *) p; ++ if (!isdoschar(*p)) ++ return(False); ++ p++; ++ } ++ } ++#else + while (*p) + { + if (!isdoschar(*p)) + return(False); + p++; + } ++#endif /* BIG5 */ + #endif /* KANJI */ + } + +@@ -532,9 +548,31 @@ + p++; + } + #else ++#ifdef BIG5 ++ if (is_shift_big5 (*p)) ++ { ++ if (extlen < 2) ++ { ++ extension[extlen++] = p[0]; ++ extension[extlen++] = p[1]; ++ } ++ else ++ { ++ extension[extlen++] = base36 (((unsigned char) *p) % 36); ++ } ++ p += 2; ++ } ++ else ++ { ++ if (isdoschar (*p) && *p != '.') ++ extension[extlen++] = p[0]; ++ p++; ++ } ++#else + if (isdoschar(*p) && *p != '.') + extension[extlen++] = *p; + p++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + extension[extlen] = 0; +@@ -571,9 +609,31 @@ + p++; + } + #else ++#ifdef BIG5 ++ if (is_shift_big5 (*p)) ++ { ++ if (baselen < 4) ++ { ++ base[baselen++] = p[0]; ++ base[baselen++] = p[1]; ++ } ++ else ++ { ++ base[baselen++] = base36 (((unsigned char) *p) % 36); ++ } ++ p += 2; ++ } ++ else ++ { ++ if (isdoschar (*p) && *p != '.') ++ base[baselen++] = p[0]; ++ p++; ++ } ++#else + if (isdoschar(*p) && *p != '.') + base[baselen++] = *p; + p++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + base[baselen] = 0; +@@ -621,8 +681,20 @@ + } + } + #else ++#ifdef BIG5 ++ for (s = (unsigned char *)name; *s;) { ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else if (illegal[*s]) { ++ return(True); ++ } else { ++ s++; ++ } ++ } ++#else + for (s = (unsigned char *)name;*s;s++) + if (illegal[*s]) return(True); ++#endif /* BIG5 */ + #endif + + +--- samba-1.9.17p4/source/util.c.orig Fri Sep 26 20:44:20 1997 ++++ samba-1.9.17p4/source/util.c Fri Oct 3 00:29:18 1997 +@@ -704,8 +704,19 @@ + + *out++ = 32; + for (i=0;i<16;i++) { ++#ifndef BIG5 + char c = toupper(in[i]); +- out[i*2] = (c>>4) + 'A'; ++#else ++ char c = in[i]; ++ if(is_shift_big5(c)) { ++ out[i*2] = ((c>>4) & 0xF) + 'A'; ++ out[i*2+1] = (c & 0xF) + 'A'; ++ c=in[++i]; ++ } else { ++ c = toupper(c); ++ } ++#endif ++ out[i*2] = ((c>>4) & 0xF) + 'A'; + out[i*2+1] = (c & 0xF) + 'A'; + } + out[32]=0; +@@ -853,12 +864,42 @@ + } + } + #else /* KANJI */ ++#ifdef BIG5 ++ int diff; ++ for (;;) { ++ if (!*s || !*t) ++ return toupper (*s) - toupper (*t); ++ else if (is_shift_big5(*s) && is_shift_big5(*t)) { ++ diff = ((int) (unsigned char) *s) - ((int) (unsigned char) *t); ++ if (diff) ++ return diff; ++ diff = ((int) (unsigned char) *(s+1)) - ((int) (unsigned char) *(t+1)); ++ if (diff) ++ return diff; ++ s += 2; ++ t += 2; ++ } ++ else if (is_shift_big5 (*s)) ++ return 1; ++ else if (is_shift_big5 (*t)) ++ return -1; ++ else ++ { ++ diff = toupper (*s) - toupper (*t); ++ if (diff) ++ return diff; ++ s++; ++ t++; ++ } ++ } ++#else + while (*s && *t && toupper(*s) == toupper(*t)) + { + s++; t++; + } + + return(toupper(*s) - toupper(*t)); ++#endif /* BIG5 */ + #endif /* KANJI */ + } + +@@ -915,6 +956,39 @@ + } + return 0; + #else /* KANJI */ ++#ifdef BIG5 ++ int diff; ++ for(;n>0;) { ++ if (!*s || !*t) ++ return toupper (*s) - toupper (*t); ++ if (is_shift_big5 (*s) && is_shift_big5 (*t)) ++ { ++ diff = ((int) (unsigned char) *s) - ((int) (unsigned char) *t); ++ if (diff) ++ return diff; ++ diff = ((int) (unsigned char) *(s+1)) - ((int) (unsigned char) *(t+1)); ++ if (diff) ++ return diff; ++ s += 2; ++ t += 2; ++ n -= 2; ++ } ++ else if (is_shift_big5(*s)) ++ return 1; ++ else if (is_shift_big5(*t)) ++ return -1; ++ else ++ { ++ diff = toupper (*s) - toupper (*t); ++ if (diff) ++ return diff; ++ s++; ++ t++; ++ n--; ++ } ++ } ++ return 0; ++#else + while (n-- && *s && *t && toupper(*s) == toupper(*t)) + { + s++; t++; +@@ -925,6 +999,7 @@ + + /* identical up to where we run out of chars, and strings are same length */ + return(0); ++#endif /* BIG5 */ + #endif /* KANJI */ + } + +@@ -984,9 +1059,19 @@ + s++; + } + #else /* KANJI */ ++#ifdef BIG5 ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else { ++ if (isupper(*s)) ++ *s = tolower(*s); ++ s++; ++ } ++#else /* KANJI */ + if (isupper(*s)) + *s = tolower(*s); + s++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + } +@@ -1013,9 +1098,19 @@ + s++; + } + #else /* KANJI */ ++#ifdef BIG5 ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else { ++ if (islower(*s)) ++ *s = toupper(*s); ++ s++; ++ } ++#else + if (islower(*s)) + *s = toupper(*s); + s++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + } +@@ -1062,9 +1157,19 @@ + s++; + } + #else /* KANJI */ ++#ifdef BIG5 ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else { ++ if (oldc == *s) ++ *s = newc; ++ s++; ++ } ++#else + if (oldc == *s) + *s = newc; + s++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + } +@@ -1700,8 +1805,17 @@ + s++; + } + #else /* KANJI */ ++#ifdef BIG5 ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else { ++ if (isupper(*s)) return(True); ++ s++; ++ } ++#else + if (isupper(*s)) return(True); + s++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + return(False); +@@ -1727,8 +1841,17 @@ + s++; + } + #else /* KANJI */ ++#ifdef BIG5 ++ if (is_shift_big5 (*s)) { ++ s += 2; ++ } else { ++ if (islower(*s)) return(True); ++ s++; ++ } ++#else + if (islower(*s)) return(True); + s++; ++#endif /* BIG5 */ + #endif /* KANJI */ + } + return(False); diff -ruN samba-des.orig/pkg/COMMENT samba-des/pkg/COMMENT --- samba-des.orig/pkg/COMMENT Thu Jan 1 08:00:00 1970 +++ samba-des/pkg/COMMENT Tue Nov 18 11:45:03 1997 @@ -0,0 +1 @@ +A LanManager(R)-compat. srv suite w/ WinNT en. pass + cn filename diff -ruN samba-des.orig/pkg/DESCR samba-des/pkg/DESCR --- samba-des.orig/pkg/DESCR Thu Jan 1 08:00:00 1970 +++ samba-des/pkg/DESCR Tue Nov 18 11:07:14 1997 @@ -0,0 +1,35 @@ +The Samba suite is a set of programs which run under the FreeBSD +operating system. These programs deliver most of the important +functionality of a Microsoft Lan Manager server. That is, they support +remote access to FreeBSD filespace and FreeBSD printers from Lan Manager +compatible clients. In practical terms, this means that such clients +can connect to and use FreeBSD filespace as if it was a local disk drive, +or FreeBSD printers as if they were local printers. + +Some of the most popular Lan Manager compatible clients include Lan +Manager itself, Windows for Workgroups, OS/2 and Windows NT. + +If you want to use Windows NT newer than 4.0+Service Pack 3 (NT4 SP3) +or later as clients, you have to use this package. NT4 SP3 (or later) +can't connect to SMB server without Windows encrypted password support. +See ${PREFIX}/share/doc/samba/ENCRYPTION.txt (default: +/usr/local/share/doc/samba/ENCRYPTION.txt) for details. + +This port is named samba-des, but it does not use des distribution files +of FreeBSD. It uses libdes (derived from SSLeay package) and this port +automatically get this library from FTP site. + +If you use this port as an upgrade of non-encryption Samba system, do +not forget to change "encript passwords" parameter in "[global]" section +to "yes", and confirm that "security" parameter in "[global]" section +is "user". + +*Security Notes* +The users' encripted passwords stored in ${PREFIX}/private/smbpasswd +(default: /usr/local/private/smbpasswd) file *ARE PASSWORD EQUIVALENT* +from the viewpoint of SMB protocol. Do not unstrengthen the permission +mode of this file (default: root.wheel and rw-------) without any special +reasons. And please note that even if you pkg_delete this port, +pkg_delete will *NOT* remove smbpaswd file because pkg_delete can be used +for upgrading this package. If you won't use this package anymore, I +strongly recommend you to remove smbpasswd file manually. diff -ruN samba-des.orig/pkg/PLIST samba-des/pkg/PLIST --- samba-des.orig/pkg/PLIST Thu Jan 1 08:00:00 1970 +++ samba-des/pkg/PLIST Tue Nov 18 11:07:14 1997 @@ -0,0 +1,78 @@ +bin/smbclient +bin/smbrun +bin/smbstatus +bin/smbpasswd +bin/nmblookup +bin/smbtar +bin/addtosmbpass +bin/testparm +bin/testprns +bin/mksmbpasswd.sh +sbin/smbd +sbin/nmbd +man/man1/smbstatus.1.gz +man/man1/smbclient.1.gz +man/man1/smbrun.1.gz +man/man1/smbtar.1.gz +man/man1/testparm.1.gz +man/man1/testprns.1.gz +man/man5/smb.conf.5.gz +man/man7/samba.7.gz +man/man8/smbd.8.gz +man/man8/nmbd.8.gz +man/man8/smbpasswd.8.gz +share/doc/samba/faq/Samba-Server-FAQ-1.html +share/doc/samba/faq/Samba-Server-FAQ-2.html +share/doc/samba/faq/Samba-Server-FAQ.html +share/doc/samba/faq/Samba-Server-FAQ.sgml +share/doc/samba/faq/Samba-meta-FAQ-1.html +share/doc/samba/faq/Samba-meta-FAQ-2.html +share/doc/samba/faq/Samba-meta-FAQ-3.html +share/doc/samba/faq/Samba-meta-FAQ-4.html +share/doc/samba/faq/Samba-meta-FAQ-5.html +share/doc/samba/faq/Samba-meta-FAQ-6.html +share/doc/samba/faq/Samba-meta-FAQ.html +share/doc/samba/faq/Samba-meta-FAQ.sgml +share/doc/samba/faq/Samba-meta-FAQ.txt +share/doc/samba/faq/sambafaq-1.html +share/doc/samba/faq/sambafaq-2.html +share/doc/samba/faq/sambafaq-3.html +share/doc/samba/faq/sambafaq-4.html +share/doc/samba/faq/sambafaq-5.html +share/doc/samba/faq/sambafaq.html +share/doc/samba/faq/sambafaq.sgml +share/doc/samba/faq/sambafaq.txt +share/doc/samba/Application_Serving.txt +share/doc/samba/BROWSING.txt +share/doc/samba/BUGS.txt +share/doc/samba/DIAGNOSIS.txt +share/doc/samba/DNIX.txt +share/doc/samba/DOMAIN.txt +share/doc/samba/DOMAIN_CONTROL.txt +share/doc/samba/ENCRYPTION.txt +share/doc/samba/Faxing.txt +share/doc/samba/GOTCHAS.txt +share/doc/samba/HINTS.txt +share/doc/samba/MIRRORS.txt +share/doc/samba/NetBIOS.txt +share/doc/samba/OS2-Client-HOWTO.txt +share/doc/samba/Passwords.txt +share/doc/samba/Printing.txt +share/doc/samba/SCO.txt +share/doc/samba/Speed.txt +share/doc/samba/Support.txt +share/doc/samba/Tracing.txt +share/doc/samba/UNIX-SMB.txt +share/doc/samba/Win95.txt +share/doc/samba/UNIX_INSTALL.txt +share/doc/samba/WinNT.txt +share/doc/samba/security_level.txt +share/doc/samba/README.DCEDFS +share/doc/samba/README.jis +share/doc/samba/README.sambatar +etc/rc.d/samba.sh.sample +etc/smb.conf.sample +@dirrm share/doc/samba/faq +@dirrm share/doc/samba +@exec mkdir %D/private ; if [ ! -f %D/private/smbpasswd ] ; then chown -R root.wheel %D/private ; cat /etc/passwd | %D/bin/mksmbpasswd.sh > %D/private/smbpasswd ; chmod 500 %D/private ; chmod 600 %D/private/smbpasswd ; fi +@unexec echo "Warning: If you will *NOT* use this package anymore, please remove \${PREFIX}/private/smbpasswd manually." >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199711180402.MAA13921>