OpenPKG CVS Repository
  http://cvs.openpkg.org/
  ____________________________________________________________________________

  Server: cvs.openpkg.org                  Name:   Ralf S. Engelschall
  Root:   /v/openpkg/cvs                   Email:  r...@openpkg.org
  Module: openpkg-src                      Date:   14-Jun-2009 09:57:29
  Branch: HEAD                             Handle: 2009061408572800

  Added files:
    openpkg-src/sslh        fsl.sslh rc.sslh sslh.patch sslh.spec

  Log:
    new package: sslh 1.6i (SSL/SSH Server Multiplexer)

  Summary:
    Revision    Changes     Path
    1.1         +16 -0      openpkg-src/sslh/fsl.sslh
    1.1         +65 -0      openpkg-src/sslh/rc.sslh
    1.1         +40 -0      openpkg-src/sslh/sslh.patch
    1.1         +107 -0     openpkg-src/sslh/sslh.spec
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: openpkg-src/sslh/fsl.sslh
  ============================================================================
  $ cvs diff -u -r0 -r1.1 fsl.sslh
  --- /dev/null 2009-06-14 09:57:28 +0200
  +++ fsl.sslh  2009-06-14 09:57:29 +0200
  @@ -0,0 +1,16 @@
  +##
  +##  fsl.sslh -- OSSP fsl configuration
  +##
  +
  +ident .*(sslh).*/.+ q{
  +    prefix(
  +        prefix="%b %d %H:%M:%S %N <%L> $1[%P]: "
  +    )
  +    -> {
  +        debug: file(
  +            path="@l_prefix@/var/sslh/sslh.log",
  +            perm=0664
  +        )
  +    }
  +};
  +
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/sslh/rc.sslh
  ============================================================================
  $ cvs diff -u -r0 -r1.1 rc.sslh
  --- /dev/null 2009-06-14 09:57:28 +0200
  +++ rc.sslh   2009-06-14 09:57:29 +0200
  @@ -0,0 +1,65 @@
  +...@l_prefix@/bin/openpkg rc
  +##
  +##  rc.sslh -- Run-Commands
  +##
  +
  +%config
  +    sslh_enable="$openpkg_rc_def"
  +    sslh_bind="127.0.0.1:443"
  +    sslh_connect_ssl="127.0.0.1:442"
  +    sslh_connect_ssh="127.0.0.1:22"
  +    sslh_timeout="2"
  +    sslh_log_prolog="true"
  +    sslh_log_epilog="true"
  +    sslh_log_numfiles="10"
  +    sslh_log_minsize="1M"
  +    sslh_log_complevel="9"
  +
  +%common
  +    sslh_pidfile="@l_prefix@/var/sslh/sslh.pid"
  +    sslh_logfile="@l_prefix@/var/sslh/sslh.log"
  +    sslh_signal () {
  +        [ -f $sslh_pidfile ] && kill -$1 `cat $sslh_pidfile`
  +    }
  +
  +%status -u @l_susr@ -o
  +    sslh_usable="unknown"
  +    sslh_active="no"
  +    rcService sslh enable yes && \
  +        sslh_signal 0 && sslh_active="yes"
  +    echo "sslh_enable=\"$sslh_enable\""
  +    echo "sslh_usable=\"$sslh_usable\""
  +    echo "sslh_active=\"$sslh_active\""
  +
  +%start -u @l_susr@
  +    rcService sslh enable yes || exit 0
  +    rcService sslh active yes && exit 0
  +    @l_prefix@/sbin/sslh \
  +        -t "$sslh_timeout" \
  +        -p "$sslh_bind" \
  +        -l "$sslh_connect_ssl" \
  +        -s "$sslh_connect_ssh" \
  +        -u "@l_nusr@" \
  +        -P "$sslh_pidfile"
  +
  +%stop -u @l_susr@
  +    rcService sslh enable yes || exit 0
  +    rcService sslh active no  && exit 0
  +    sslh_signal TERM
  +    sleep 2
  +    rm -f $sslh_pidfile >/dev/null 2>&1 || true
  +
  +%restart -u @l_susr@
  +    rcService sslh enable yes || exit 0
  +    rcService sslh active no  && exit 0
  +    rc sslh stop start
  +
  +%daily -u @l_susr@
  +    rcService sslh enable yes || exit 0
  +    shtool rotate -f \
  +        -n ${sslh_log_numfiles} -s ${sslh_log_minsize} -d \
  +        -z ${sslh_log_complevel} -m 664 -o @l_susr@ -g @l_mgrp@ \
  +        -P "${sslh_log_prolog}" \
  +        -E "${sslh_log_epilog}; rc sslh restart" \
  +        $sslh_logfile
  +
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/sslh/sslh.patch
  ============================================================================
  $ cvs diff -u -r0 -r1.1 sslh.patch
  --- /dev/null 2009-06-14 09:57:28 +0200
  +++ sslh.patch        2009-06-14 09:57:29 +0200
  @@ -0,0 +1,40 @@
  +Index: Makefile
  +--- Makefile.orig    2009-04-26 10:47:22 +0200
  ++++ Makefile 2009-06-14 09:41:51 +0200
  +@@ -1,18 +1,18 @@
  + # Configuration
  + 
  + VERSION="v1.6i"
  +-USELIBWRAP=1        # Use libwrap?
  ++USELIBWRAP=
  + PREFIX=/usr/local
  + 
  +-MAN=sslh.8.gz       # man page name
  ++MAN=sslh.8
  + 
  + # End of configuration -- the rest should take care of
  + # itself
  + 
  + CC = gcc
  + CFLAGS=-Wall
  +-
  +-#LIBS=-lnet
  ++CPPFLAGS=-D'VERSION=$(VERSION)' 
  ++LDFLAGS=
  + LIBS=
  + 
  + ifneq ($(strip $(USELIBWRAP)),)
  +@@ -23,11 +23,10 @@
  + all: sslh $(MAN)
  + 
  + sslh: sslh.c Makefile
  +-    $(CC) $(CFLAGS) -D'VERSION=$(VERSION)' -o sslh sslh.c $(LIBS)
  +-    strip sslh
  ++    $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o sslh sslh.c $(LIBS)
  + 
  + $(MAN): sslh.pod Makefile
  +-    pod2man --section=8 --release=$(VERSION) --center=" " sslh.pod | gzip 
-9 - > $(MAN)
  ++    pod2man --section=8 --release=$(VERSION) --center=" " sslh.pod >$(MAN)
  + 
  + # generic install: install binary and man page
  + install: sslh $(MAN)
  @@ .
  patch -p0 <<'@@ .'
  Index: openpkg-src/sslh/sslh.spec
  ============================================================================
  $ cvs diff -u -r0 -r1.1 sslh.spec
  --- /dev/null 2009-06-14 09:57:28 +0200
  +++ sslh.spec 2009-06-14 09:57:29 +0200
  @@ -0,0 +1,107 @@
  +##
  +##  sslh.spec -- OpenPKG RPM Package Specification
  +##  Copyright (c) 2000-2009 OpenPKG Foundation e.V. <http://openpkg.net/>
  +##
  +##  Permission to use, copy, modify, and distribute this software for
  +##  any purpose with or without fee is hereby granted, provided that
  +##  the above copyright notice and this permission notice appear in all
  +##  copies.
  +##
  +##  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  +##  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  +##  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  +##  IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  +##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  +##  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  +##  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  +##  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  +##  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  +##  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  +##  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  +##  SUCH DAMAGE.
  +##
  +
  +#   package information
  +Name:         sslh
  +Summary:      SSL/SSH Server Multiplexer
  +URL:          http://www.rutschle.net/tech/sslh.shtml
  +Vendor:       Yves Rutschle
  +Packager:     OpenPKG Foundation e.V.
  +Distribution: OpenPKG Community
  +Class:        EVAL
  +Group:        Networking
  +License:      GPL
  +Version:      1.6i
  +Release:      20090614
  +
  +#   package options
  +%option       with_fsl  yes
  +
  +#   list of sources
  +Source0:      http://www.rutschle.net/tech/sslh-%{version}.tar.gz
  +Source1:      rc.sslh
  +Source2:      fsl.sslh
  +Patch0:       sslh.patch
  +
  +#   build information
  +Prefix:       %{l_prefix}
  +BuildRoot:    %{l_buildroot}
  +BuildPreReq:  OpenPKG, openpkg >= 20060823, make, gcc, perl
  +PreReq:       OpenPKG, openpkg >= 20060823
  +%if "%{with_fsl}" == "yes"
  +BuildPreReq:  fsl
  +PreReq:       fsl
  +%endif
  +AutoReq:      no
  +AutoReqProv:  no
  +
  +%description
  +    sslh(8) lets one accept both HTTPS and SSH connections on the same
  +    port. It makes it possible to connect to an SSH server on port 443
  +    (usually from inside a corporate firewall which does not allow
  +    outgoing SSH connections, but outgoing HTTPS connections) while
  +    still serving HTTPS on that same port.
  +
  +%track
  +    prog sslh = {
  +        version   = %{version}
  +        url       = http://www.rutschle.net/tech/sslh.shtml
  +        regex     = sslh-(__VER__)\.tar\.gz
  +    }
  +
  +%prep
  +    %setup -q
  +    %patch -p0
  +
  +%build
  +    %{l_make} %{l_mflags} \
  +        CC="%{l_cc}" \
  +        CFLAGS="%{l_cflags -O}" \
  +        LDFLAGS="%{l_ldflags} %{l_fsl_ldflags}" \
  +        LIBS="%{l_fsl_libs}"
  +
  +%install
  +    rm -rf $RPM_BUILD_ROOT
  +    %{l_shtool} mkdir -f -p -m 755 \
  +        $RPM_BUILD_ROOT%{l_prefix}/etc/fsl \
  +        $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d \
  +        $RPM_BUILD_ROOT%{l_prefix}/sbin \
  +        $RPM_BUILD_ROOT%{l_prefix}/man/man8 \
  +        $RPM_BUILD_ROOT%{l_prefix}/var/sslh
  +    %{l_shtool} install -c -s -m 755 \
  +        sslh $RPM_BUILD_ROOT%{l_prefix}/sbin/
  +    %{l_shtool} install -c -m 644 \
  +        sslh.8 $RPM_BUILD_ROOT%{l_prefix}/man/man8/
  +    %{l_shtool} install -c -m 755 %{l_value -s -a} \
  +        %{SOURCE rc.sslh} $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/
  +    %{l_shtool} install -c -m 644 %{l_value -s -a} \
  +        %{SOURCE fsl.sslh} $RPM_BUILD_ROOT%{l_prefix}/etc/fsl/
  +    %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
  +        %{l_files_std} \
  +        '%attr(-,%{l_nusr},%{l_ngrp}) %{l_prefix}/var/sslh'
  +
  +%files -f files
  +
  +%clean
  +    rm -rf $RPM_BUILD_ROOT
  +
  @@ .
______________________________________________________________________
OpenPKG                                             http://openpkg.org
CVS Repository Commit List                     openpkg-cvs@openpkg.org

Reply via email to