Results 1 to 8 of 8

Thread: vpnc with openssl on hardy

  1. #1
    Join Date
    Dec 2006
    Location
    Tucson Arizona USA
    Beans
    12
    Distro
    Ubuntu 8.04 Hardy Heron

    Question vpnc with openssl on hardy

    Hello,

    I just installed hardy on my gateway desktop system. I need to use vpn to connect with a cisco concentrator at work, and I cannot get cisco's vpn client to compile on hardy.

    Idid some research and it looked like vpnc was a good alternative. I got vpnc working on fedora 9 without much difficulty.

    When I installed vpnc via:

    apt-get install vpnc

    The version installed did not have ssl support (due to licensing issues), so I knew I had to compile it myself.

    So, I ran:

    apt-get source vpnc
    apt-get install openssl

    Next I cd'ed to the vpnc source directory and ran:

    apt-get build-dep


    So far so good.
    Next I ran:
    dpkg-buildpackage

    all was good the package built fine, but still no ssl support.

    Next step:
    I edited Makefile and uncommented the two OPENSSL lines that are annotated in the comments in the makefile.

    I ran:

    dpkg-buildpackage

    This time Iget errors as follows:

    ---- build log ----
    dpkg-buildpackage: set CPPFLAGS to default value:
    dpkg-buildpackage: set CFLAGS to default value: -g -O2
    dpkg-buildpackage: set CXXFLAGS to default value: -g -O2
    dpkg-buildpackage: set FFLAGS to default value: -g -O2
    dpkg-buildpackage: set LDFLAGS to default value: -Wl,-Bsymbolic-functions
    dpkg-buildpackage: source package vpnc
    dpkg-buildpackage: source version 0.5.1r275-1
    dpkg-buildpackage: source changed by Eduard Bloch <blade@debian.org>
    dpkg-buildpackage: host architecture i386
    debian/rules clean
    dpatch deapply-all
    reverting patch 04_debianitis from ./ ... ok.
    reverting patch 03_vpnc.8 from ./ ... ok.
    rm -rf patch-stamp patch-stampT debian/patched
    dh_testdir
    dh_testroot
    rm -f build-stamp configure-stamp
    # Add here commands to clean up after the build process.
    /usr/bin/make distclean
    make[1]: Entering directory `/root/vpnc-0.5.1r275'
    gcc -MM sysdep.c vpnc-debug.c isakmp-pkt.c tunip.c config.c dh.c math_group.c supp.c decrypt-utils.c vpnc.c cisco-decrypt.c -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION > .depend
    make[1]: Leaving directory `/root/vpnc-0.5.1r275'
    make[1]: Entering directory `/root/vpnc-0.5.1r275'
    rm -f sysdep.o vpnc-debug.o isakmp-pkt.o tunip.o config.o dh.o math_group.o supp.o decrypt-utils.o vpnc.o cisco-decrypt.o vpnc cisco-decrypt tags
    rm -f vpnc-debug.c vpnc-debug.h vpnc.ps vpnc.8 .depend
    make[1]: Leaving directory `/root/vpnc-0.5.1r275'
    dh_clean
    dpkg-source -b vpnc-0.5.1r275
    dpkg-source: building vpnc using existing vpnc_0.5.1r275.orig.tar.gz
    dpkg-source: building vpnc in vpnc_0.5.1r275-1.diff.gz
    dpkg-source: warning: executable mode 0755 of 'debian/patches/04_debianitis.dpatch' will not be represented in diff
    dpkg-source: warning: executable mode 0755 of 'debian/patches/03_vpnc.8.dpatch' will not be represented in diff
    dpkg-source: warning: executable mode 0755 of 'vpnc-script' will not be represented in diff
    dpkg-source: building vpnc in vpnc_0.5.1r275-1.dsc
    debian/rules build
    dh_testdir
    # Add here commands to configure the package.
    touch configure-stamp
    test -d debian/patched || install -d debian/patched
    dpatch apply-all
    applying patch 03_vpnc.8 to ./ ... ok.
    applying patch 04_debianitis to ./ ... ok.
    dpatch cat-all >>patch-stampT
    mv -f patch-stampT patch-stamp
    dh_testdir
    # Add here commands to compile the package.
    /usr/bin/make
    make[1]: Entering directory `/root/vpnc-0.5.1r275'
    LANG=C perl -w ./enum2debug.pl isakmp.h >vpnc-debug.c 2>vpnc-debug.h
    gcc -MM sysdep.c vpnc-debug.c isakmp-pkt.c tunip.c config.c dh.c math_group.c supp.c decrypt-utils.c vpnc.c cisco-decrypt.c -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION > .depend
    make[1]: Leaving directory `/root/vpnc-0.5.1r275'
    make[1]: Entering directory `/root/vpnc-0.5.1r275'
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o sysdep.o sysdep.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o vpnc-debug.o vpnc-debug.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o isakmp-pkt.o isakmp-pkt.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o tunip.o tunip.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o config.o config.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o dh.o dh.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o math_group.o math_group.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o supp.o supp.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o decrypt-utils.o decrypt-utils.c
    gcc -Wall -g -O2 -W -Wall -Wmissing-declarations -Wwrite-strings -DVERSION=\"0.5.1\" -DOPENSSL_GPL_VIOLATION -c -o vpnc.o vpnc.c
    vpnc.c:45:26: error: openssl/x509.h: No such file or directory
    vpnc.c:46:25: error: openssl/err.h: No such file or directory
    vpnc.c: In function ‘do_phase1’:
    vpnc.c:1186: error: ‘X509’ undeclared (first use in this function)
    vpnc.c:1186: error: (Each undeclared identifier is reported only once
    vpnc.c:1186: error: for each function it appears in.)
    vpnc.c:1186: error: ‘current_cert’ undeclared (first use in this function)
    vpnc.c:1188: warning: implicit declaration of function ‘STACK_OF’
    vpnc.c:1188: error: ‘cert_stack’ undeclared (first use in this function)
    vpnc.c:1188: warning: implicit declaration of function ‘sk_X509_new_null’
    vpnc.c:1351: warning: implicit declaration of function ‘d2i_X509’
    vpnc.c:1352: warning: implicit declaration of function ‘sk_X509_push’
    vpnc.c:1571: error: ‘x509’ undeclared (first use in this function)
    vpnc.c:1572: error: ‘EVP_PKEY’ undeclared (first use in this function)
    vpnc.c:1572: error: ‘pkey’ undeclared (first use in this function)
    vpnc.c:1573: error: ‘RSA’ undeclared (first use in this function)
    vpnc.c:1573: error: ‘rsa’ undeclared (first use in this function)
    vpnc.c:1574: error: ‘X509_STORE’ undeclared (first use in this function)
    vpnc.c:1574: error: ‘store’ undeclared (first use in this function)
    vpnc.c:1576: error: ‘X509_STORE_CTX’ undeclared (first use in this function)
    vpnc.c:1576: error: ‘verify_ctx’ undeclared (first use in this function)
    vpnc.c:1581: warning: implicit declaration of function ‘OpenSSL_add_all_ciphers’
    vpnc.c:1582: warning: implicit declaration of function ‘OpenSSL_add_all_digests’
    vpnc.c:1583: warning: implicit declaration of function ‘OpenSSL_add_all_algorithms’
    vpnc.c:1585: warning: implicit declaration of function ‘ERR_load_crypto_strings’
    vpnc.c:1590: warning: implicit declaration of function ‘ERR_print_errors_fp’
    vpnc.c:1593: warning: implicit declaration of function ‘X509_subject_name_hash’
    vpnc.c:1593: warning: format ‘%08lx’ expects type ‘long unsigned int’, but argument 2 has type ‘int’
    vpnc.c:1597: warning: implicit declaration of function ‘X509_STORE_new’
    vpnc.c:1601: warning: implicit declaration of function ‘X509_STORE_load_locations’
    vpnc.c:1604: warning: implicit declaration of function ‘X509_STORE_set_default_paths’
    vpnc.c:1623: warning: implicit declaration of function ‘X509_STORE_CTX_new’
    vpnc.c:1628: warning: implicit declaration of function ‘X509_STORE_CTX_init’
    vpnc.c:1632: warning: implicit declaration of function ‘X509_verify_cert’
    vpnc.c:1642: warning: implicit declaration of function ‘X509_get_pubkey’
    vpnc.c:1648: warning: implicit declaration of function ‘EVP_PKEY_get1_RSA’
    vpnc.c:1654: warning: implicit declaration of function ‘RSA_public_decrypt’
    vpnc.c:1654: error: ‘RSA_PKCS1_PADDING’ undeclared (first use in this function)
    vpnc.c:1675: warning: implicit declaration of function ‘EVP_PKEY_free’
    make[1]: *** [vpnc.o] Error 1
    make[1]: Leaving directory `/root/vpnc-0.5.1r275'
    make: *** [build-stamp] Error 2
    dpkg-buildpackage: failure: debian/rules build gave error exit status 2

    ---- end of build log ----

    I am very new to ubuntu and debian derrivatives and know nothing about how dpkg works or how to troubleshoot this problem.

    Any help would be greately appreciated

  2. #2
    Join Date
    Feb 2007
    Location
    Gray, TN, USA
    Beans
    155
    Distro
    Xubuntu 10.10 Maverick Meerkat

    Re: vpnc with openssl on hardy

    Try installing libssl-dev. Does that change the outcome of dpkg-buildpackage?
    Q: How many ADD kids does it take to screw in a lightbulb?
    A: Hey! Let's go ride bikes!

  3. #3
    Join Date
    Dec 2006
    Location
    Tucson Arizona USA
    Beans
    12
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: vpnc with openssl on hardy

    Thanks that did it. the dpkg-buildpackage finished successfully and after running dpkg -i on the package I can now vpnc to the work network!

  4. #4
    Join Date
    Apr 2008
    Beans
    8

    Re: vpnc with openssl on hardy

    There's a few other steps after building the package that can make your life easier. Read about them here:

    Howto ignore an update POst #5

    The short version is, ubuntu will want to overwrite/update your custom .deb. The above thread explains ways to get around that.

  5. #5
    Join Date
    Jan 2008
    Beans
    3

    Re: vpnc with openssl on hardy

    Thanks guys! You've helped me get this running on my asus eee (using ibex so nice and recent)

    I've compiled a full list of what I did (including config set up) here
    http://folkloreofpitong.blogspot.com...s-eee-900.html

    thank you for this post! I was getting very frustrated with this, hopefully next release will have some option for native support or similar.

  6. #6
    Join Date
    Mar 2007
    Beans
    38

    Re: vpnc with openssl on hardy

    I got it built, I think, but for some reason I can't install it...


    user@seacaptin:~/vpnc-0.5.1r275$ sudo dpkg -i vpnc
    dpkg-deb: `vpnc' is not a debian format archive
    dpkg: error processing vpnc (--install):
    subprocess dpkg-deb --control returned error exit status 2
    Errors were encountered while processing:
    vpnc
    user@seacaptin:~/vpnc-0.5.1r275$


    I am sure this means I screwed something up earlier in the process, but I don't really know my way around dpkg very well... Any ideas?

  7. #7
    Join Date
    Jul 2008
    Beans
    1

    Re: vpnc with openssl on hardy

    I'm getting the same error when trying to install. The rest of the process appears to have gone smoothly.

  8. #8
    Join Date
    Aug 2011
    Beans
    2

    Re: vpnc with openssl on hardy

    I have natty and I couldn't figure out my error until I read this article, http://www.nulldevice.de/2010/06/cis...u-linux-10-04/. The missing piece was spoofing or faking that my ubuntu machine was a windows client with this line in the /etc/vpnc/myconnection.conf:

    Application version Cisco Systems VPN Client 5.0.07.0240:WinNT

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •