C++ application development framework, to help developers create and deploy applications quickly and simply

Overview

ULib - C++ library

Travis CI: Build Status Coverity Scan: Coverity Scan Build Status

ULib is a highly optimized class framework for writing C++ applications. I wrote this framework as my tool for writing applications in various contexts. It is a result of many years of work as C++ programmer. I think, in my opinion, that its strongest points are simplicity, efficiency and sophisticate debugging.

ULib is meant as a very light-weight C++ library to facilitate using C++ design patterns even for very deeply embedded applications, such as for systems using uclibc along with posix threading support. For this reason, ULib disables language features that consume memory or introduce runtime overhead, such as rtti and exception handling, and assumes one will mostly be linking applications with other pure C based libraries rather than using the overhead of the standard C++ library and other similar class frameworks.

It include as application example a powerful search engine with relative web interface and a multi purpose server (plugin oriented) which results, out of John Fremlin accurate investigations, to be one of the fastest web application frameworks for serving small dynamic webpages (and also make easier the usage of shell scripts for CGI application)

userver (_tcp | _ssl | _ipc) application server (plugin oriented)

The current version offers the following features :

  • HTTP/1.0, 1.1 and HTTP/2 (h2spec compliant) protocols supported.
  • Persistent connections for HTTP/1.1 and Keep-Alive support for HTTP/1.0.
  • Browser cache management (headers: If-Modified-Since/Last-modified).
  • Chunk-encoding transfers support.
  • HTTP multi-range request support.
  • Memory caching of document root for (small) static pages with smart (gzip-zopfli,brotli) compression and CSS/JS reduction.
  • Support for automatic update of caching document root with inotify (on Linux).
  • Support for pipelining.
  • Support for virtual hosts (also with SSL).
  • Support for basic/digest authentication optionally based on url mask.
  • Support for directory listings via basic/digest authentication.
  • Support for uri protection.
  • Support for aliases/redirection.
  • Support for switch the site to a maintenance page only.
  • Support for URL traffic based throttling (experimental).
  • Support for overriden of error messages by local document (ex. ErrorDocument/400.html).
  • Support for RewriteRule (lighttpd-like) that check for file existence as they do on Apache, some CMS (SilverStripe) require it.
  • Support for (apache-like) log NCSA extended/combined format.
  • Support for JSONRequest.
  • Accept HTTP uploads (with possible resume) up to 4 GB without increasing memory usage.
  • General CGI support (run any CGI script) with automatic output compression (using gzip,brotli method).
  • CGI support for shell script processes (with automatic management of form and cookie).
  • CGI support for the X-Sendfile feature and also supports X-Accel-Redirect headers transparently.
  • Support for minify HTML CGI output by wrapping google page speed SDK.
  • Support for running JavaScript code by wrapping google V8 JavaScript Engine.
  • HTTP pseudo-streaming for FLV video managed transparently.
  • C Servlet Support with libtcc (if available) as a backend for dynamic code generation (experimental).
  • Support for running Ruby on Rails applications natively (experimental).
  • Support for running natively PHP applications whith a php (embedded) library (experimental).
  • Support for load balance between physical server via udp brodcast (experimental).
  • Support for serialize object by FlatBuffer schema-less like implementation.
  • Support for SSE (Server Sent Event) via ULib Servlet Page (USP) dedicate process.
  • Preforking mode to improve concurrency with dedicated process for long-time request.
  • Support for Windows (without preforking).
  • Customizable builds (you can remove unneeded functionality).
  • Requests cut in phases for modular architecture (apache-like).
  • Configuration file with dedicated section.
  • Built-in modules :
    • mod_echo : echo features.
    • mod_rpc : generic Remote Procedure Call.
    • mod_http : core features, static file handler and dynamic page (ULib Servlet Page).
    • mod_ssi : Server Side Includes support with enhanced #set, direct include and #exec servlet (C/ULib Servlet Page).
    • mod_nocat : captive portal implementation.
    • mod_proxy : multi-features reverse proxy with websocket support.
    • mod_tsa : server side Time Stamp support.
    • mod_soap : generic SOAP server services support.
    • mod_fcgi : third-party applications support thru FastCGI interface.
    • mod_scgi : module that implements the client side of the SCGI protocol (experimental).
    • mod_shib : web single sign-on support (experimental).
    • mod_geoip : geolocation support (experimental).
    • mod_stream : simple streaming support (experimental).
    • mod_socket : Web Socket application framework (experimental).
  • Security protection :
  • Immune to Slow Read DoS attack.
  • Provide evasive action in the event of an HTTP DoS or DDoS attack or brute force attack.
  • High SSL server quality score.

Who is Using ULib

It is the main software component of city of Florence wireless network

Benchmark

userver application server is since 10th round in the TechEmpower's web framework benchmarks. This independent work tests a large number of frameworks and platforms against a set of tests common to web applications, such as JSON serialization, database queries and templating.

Getting Started With ULib (donated generously by jonathan kelly)

Contributing

  1. Fork it ( http://github.com/stefanocasazza/ULib/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

License

ULib is normally built and installed as a set of shared object libraries and header files. These libraries and headers are installed using directories selected through a "configure" script that has been prepared with automake and autoconf. As such, they should build and install similarly to and in a manner compatible and consistent with most other GNU software. ULib is Free Software under the LGPL and it is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Comments and suggestions are welcome.

stefano casazza <[email protected]>

Please, excuse me for my bad english, it's not my natural language, if some parts of this page seems wrong to you, feel free to suggest me better ones.

Donation

If this project help you reduce time to develop, you can give me a cup of coffee :)

Donate

Issues
  • How to route in USP code?

    How to route in USP code?

    Consider I have an usp file say one.usp which gives me one.so so that my URL served is http://localhost/one. Now if I want to serve http://localhost/one/two then how can I achieve that?

    opened by shivshankardayal 15
  • Not sure how to use...

    Not sure how to use...

    I've managed to installed with make and make install

    i've put the ULib/src/ulib/net/server/plugin/usp/hello.usp into /var/www

    i ran with 127.0.0.1/hello.usp and below is the result I got. index.html is running fine. how do i resolve the problem below?

    
    userver_tcp: WARNING: 07/12/17 14:08:06 (pid 28693) Cannot set posix realtime scheduling policy
    userver_tcp: WARNING: 07/12/17 14:08:07 (pid 28694) Cannot set posix realtime scheduling policy
    userver_tcp: WARNING: 07/12/17 14:08:07 (pid 28695) Cannot set posix realtime scheduling policy
    userver_tcp: WARNING: 07/12/17 14:08:08 (pid 28696) Cannot set posix realtime scheduling policy
    -
     pid: 28562
     address: 0x8 - SEGV_MAPERR (1, Address not mapped to object)
     rss usage: 316.31 MBytes
     address space usage: 66.33 MBytes
    -
    userver_tcp: ABORT: 07/12/17 14:05:21 (pid 28561) program interrupt by the kernel - SIGSEGV (11, Segmentation fault)
    -
    
    
    opened by unisqu 12
  • I am getting error

    I am getting error "userver_tcp: error while loading shared libraries: libulib-1.4.2.so.1 .."

    I am getting this when trying to run /exmples/userver/userver_tcp:

    userver_tcp: error while loading shared libraries: libulib-1.4.2.so.1: cannot open shared object file: No such file or directory
    

    Thank you.

    opened by acrolink 12
  • Compilation Error on Mac

    Compilation Error on Mac

    When installing the framework, getting this output...

    ld: unknown option: -R/usr/local/lib clang: error: linker command failed with exit code 1 (use -v to see invocation)

    ... when trying to 'make' after './configure'-(ing)

    I understand that it is a compiler issue, but at a loss for how to remedy this! I would greatly appreciate some direction :)

    opened by victorstewart 9
  • usp_libtool.sh not found

    usp_libtool.sh not found

    [email protected]:~/Downloads/ULib/src/ulib/net/server/plugin/usp$ sudo bash usp_compile.sh session.usp
    usp_compile.sh: line 63: /usr/local/bin/usp_libtool.sh: No such file or directory
    mv: cannot stat '.libs/session.usp': No such file or directory
    mv: cannot stat '.libs/session.so': No such file or directory
    

    First problem is that usp_compile.sh, usp_translator are not copied to INSTALL_PREFIX which is /usr/local/ in my case. Second minor issue is that +x is not set for usp_compile.sh.

    opened by shivshankardayal 6
  • License issue with included files

    License issue with included files

    I notice that you have moved to LGPL, which is a good news for me but I notice that you have included sources which are having GPLv2 and GPLv3 licenses. Are you planning to remove those to cleanup the license conflict?

    opened by neeraj9 6
  • Userver Http/2  ?

    Userver Http/2 ?

    Hi, I am trying to run and test userver with http/2 I've run configure --enable-debug --enable-http2 but I am lost there. Is there any guide somewhere to do this?

    opened by dhhoang 5
  • Documentation for ULib server pages

    Documentation for ULib server pages

    Can you please include more documentation for ULIb server pages? I have a repository called Kunjika and another called Memoir. Both are QA system like Stackoverflow. I would like to re-implement it with ULib but I find lack of documentation a big problem.

    opened by shivshankardayal 5
  • configure on mac os fails

    configure on mac os fails

    Platform: Darwin 15.0.0 (i386) Configuring ULib (C++ Library)

    Initial phase: checking build system type... x86_64-apple-darwin15.0.0 checking host system type... x86_64-apple-darwin15.0.0 checking target system type... x86_64-apple-darwin15.0.0 checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... ./install-sh -c -d checking for gawk... no checking for mawk... no checking for nawk... no checking for awk... awk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking how to create a pax tar archive... gnutar checking whether to enable maintainer-specific portions of Makefiles... no checking whether make supports nested variables... (cached) yes checking for style of include used by make... GNU checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc accepts -g... yes checking for gcc option to accept ISO C89... none needed checking whether gcc understands -c and -o together... yes checking dependency style of gcc... gcc3 checking how to run the C preprocessor... gcc -E checking for grep that handles long lines and -e... /usr/bin/grep checking for egrep... /usr/bin/grep -E checking for ANSI C header files... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking minix/config.h usability... no checking minix/config.h presence... no checking for minix/config.h... no checking whether it is safe to define EXTENSIONS... yes checking initial CFLAGS... -g -O2 checking which architecture the target is... unknown checking which operating system the target is... unknown checking which libc is detected for the target... unknown

    Checking for programs: checking for g++... g++ checking whether we are using the GNU C++ compiler... yes checking whether g++ accepts -g... yes checking dependency style of g++... gcc3 checking for gawk... (cached) awk checking for gcc... (cached) gcc checking whether we are using the GNU C compiler... (cached) yes checking whether gcc accepts -g... (cached) yes checking for gcc option to accept ISO C89... (cached) none needed checking whether gcc understands -c and -o together... (cached) yes checking dependency style of gcc... (cached) gcc3 checking how to run the C preprocessor... gcc -E checking whether ln -s works... yes checking whether make sets $(MAKE)... (cached) yes checking for C/C++ restrict keyword... __restrict checking for working volatile... yes checking for inline... inline checking if compiling with clang... yes checking for a supported OS... maybe (darwin15.0.0) checking how to print strings... printf checking for a sed that does not truncate output... /usr/bin/sed checking for fgrep... /usr/bin/grep -F checking for ld used by gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm checking the name lister (/usr/bin/nm) interface... BSD nm checking the maximum length of command line arguments... 196608 checking whether the shell understands some XSI constructs... yes checking whether the shell understands "+="... yes checking how to convert x86_64-apple-darwin15.0.0 file names to x86_64-apple-darwin15.0.0 format... func_convert_file_noop checking how to convert x86_64-apple-darwin15.0.0 file names to toolchain format... func_convert_file_noop checking for /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld option to reload object files... -r checking for objdump... no checking how to recognize dependent libraries... pass_all checking for dlltool... no checking how to associate runtime and link libraries... printf %s\n checking for ar... ar checking for archiver @FILE support... no checking for strip... strip checking for ranlib... ranlib checking command to parse /usr/bin/nm output from gcc object... ok checking for sysroot... no checking for mt... no checking if : is a manifest tool... no checking for dsymutil... dsymutil checking for nmedit... nmedit checking for lipo... lipo checking for otool... otool checking for otool64... no checking for -single_module linker flag... yes checking for -exported_symbols_list linker flag... yes checking for -force_load linker flag... yes checking for dlfcn.h... yes checking for objdir... .libs checking if gcc supports -fno-rtti -fno-exceptions... yes checking for gcc option to produce PIC... -fno-common -DPIC checking if gcc PIC flag -fno-common -DPIC works... yes checking if gcc static flag -static works... no checking if gcc supports -c -o file.o... yes checking if gcc supports -c -o file.o... (cached) yes checking whether the gcc linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin15.0.0 dyld checking how to hardcode library paths into programs... immediate checking for dlopen in -ldl... yes checking whether a program can dlopen itself... yes checking whether a statically linked program can dlopen itself... yes checking whether stripping libraries is possible... yes checking if libtool supports shared libraries... yes checking whether to build shared libraries... yes checking whether to build static libraries... yes checking how to run the C++ preprocessor... g++ -E checking for ld used by g++... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking for g++ option to produce PIC... -fno-common -DPIC checking if g++ PIC flag -fno-common -DPIC works... yes checking if g++ static flag -static works... no checking if g++ supports -c -o file.o... yes checking if g++ supports -c -o file.o... (cached) yes checking whether the g++ linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes checking dynamic linker characteristics... darwin15.0.0 dyld checking how to hardcode library paths into programs... immediate checking for full c++ support and linking model... yes checking for debugging... no checking for target that allows unaligned reads and writes... yes

    Checking for headers: checking for ANSI C header files... (cached) yes checking whether time.h and sys/time.h may both be included... yes checking whether sys/types.h defines makedev... yes checking for dirent.h that defines DIR... yes checking for library containing opendir... none required checking for sys/wait.h that is POSIX.1 compatible... yes checking for size_t... yes checking for working alloca.h... yes checking for alloca... yes checking arpa/inet.h usability... yes checking arpa/inet.h presence... yes checking for arpa/inet.h... yes checking fcntl.h usability... yes checking fcntl.h presence... yes checking for fcntl.h... yes checking float.h usability... yes checking float.h presence... yes checking for float.h... yes checking for inttypes.h... (cached) yes checking libintl.h usability... no checking libintl.h presence... no checking for libintl.h... no checking limits.h usability... yes checking limits.h presence... yes checking for limits.h... yes checking malloc.h usability... no checking malloc.h presence... no checking for malloc.h... no checking netdb.h usability... yes checking netdb.h presence... yes checking for netdb.h... yes checking netinet/in.h usability... yes checking netinet/in.h presence... yes checking for netinet/in.h... yes checking stddef.h usability... yes checking stddef.h presence... yes checking for stddef.h... yes checking for stdint.h... (cached) yes checking for stdlib.h... (cached) yes checking for string.h... (cached) yes checking sys/ioctl.h usability... yes checking sys/ioctl.h presence... yes checking for sys/ioctl.h... yes checking sys/param.h usability... yes checking sys/param.h presence... yes checking for sys/param.h... yes checking sys/socket.h usability... yes checking sys/socket.h presence... yes checking for sys/socket.h... yes checking sys/time.h usability... yes checking sys/time.h presence... yes checking for sys/time.h... yes checking sys/timeb.h usability... yes checking sys/timeb.h presence... yes checking for sys/timeb.h... yes checking sys/resource.h usability... yes checking sys/resource.h presence... yes checking for sys/resource.h... yes checking syslog.h usability... yes checking syslog.h presence... yes checking for syslog.h... yes checking termios.h usability... yes checking termios.h presence... yes checking for termios.h... yes checking for unistd.h... (cached) yes checking wchar.h usability... yes checking wchar.h presence... yes checking for wchar.h... yes checking assert.h usability... yes checking assert.h presence... yes checking for assert.h... yes checking byteswap.h usability... no checking byteswap.h presence... no checking for byteswap.h... no checking endian.h usability... no checking endian.h presence... no checking for endian.h... no checking execinfo.h usability... yes checking execinfo.h presence... yes checking for execinfo.h... yes checking ifaddrs.h usability... yes checking ifaddrs.h presence... yes checking for ifaddrs.h... yes checking mcheck.h usability... no checking mcheck.h presence... no checking for mcheck.h... no checking ndir.h usability... no checking ndir.h presence... no checking for ndir.h... no checking dirent.h usability... yes checking dirent.h presence... yes checking for dirent.h... yes checking for ndir.h... (cached) no checking for string.h... (cached) yes checking netpacket/packet.h usability... no checking netpacket/packet.h presence... no checking for netpacket/packet.h... no checking sched.h usability... yes checking sched.h presence... yes checking for sched.h... yes checking semaphore.h usability... yes checking semaphore.h presence... yes checking for semaphore.h... yes checking sysexits.h usability... yes checking sysexits.h presence... yes checking for sysexits.h... yes checking streambuf.h usability... no checking streambuf.h presence... no checking for streambuf.h... no checking poll.h usability... yes checking poll.h presence... yes checking for poll.h... yes checking net/if_arp.h usability... yes checking net/if_arp.h presence... yes checking for net/if_arp.h... yes checking sys/dir.h usability... yes checking sys/dir.h presence... yes checking for sys/dir.h... yes checking sys/ndir.h usability... no checking sys/ndir.h presence... no checking for sys/ndir.h... no checking sys/inotify.h usability... no checking sys/inotify.h presence... no checking for sys/inotify.h... no checking sys/sendfile.h usability... no checking sys/sendfile.h presence... no checking for sys/sendfile.h... no checking sys/sched.h usability... no checking sys/sched.h presence... no checking for sys/sched.h... no checking sys/syscall.h usability... yes checking sys/syscall.h presence... yes checking for sys/syscall.h... yes checking linux/netfilter_ipv4/ipt_ACCOUNT.h usability... no checking linux/netfilter_ipv4/ipt_ACCOUNT.h presence... no checking for linux/netfilter_ipv4/ipt_ACCOUNT.h... no checking libnetfilter_conntrack/libnetfilter_conntrack.h usability... no checking libnetfilter_conntrack/libnetfilter_conntrack.h presence... no checking for libnetfilter_conntrack/libnetfilter_conntrack.h... no checking /usr/src/linux/include/generated/uapi/linux/version.h usability... no checking /usr/src/linux/include/generated/uapi/linux/version.h presence... no checking for /usr/src/linux/include/generated/uapi/linux/version.h... no checking whether sys/inotify.h actually works... nope, using own inotify headers checking for fopen in -lmsvcrt... no checking for socketpair in -lc... yes checking for getaddrinfo in -lc... yes checking for gethostbyname2 in -lc... yes checking for inet_ntop in -lc... yes checking for socket in -lsocket... no checking for lstat in -lc... yes checking for strcoll in -lc... yes checking for stricmp in -lc... no checking for stristr in -lc... no checking for sysconf in -lc... yes checking for posix_memalign in -lc... yes checking if you want to enable build of thread support... yes checking if you want to always use GNU pth for threading... no checking pthread.h usability... yes checking pthread.h presence... yes checking for pthread.h... yes checking for pthread_create in -lpthread... yes checking for pthread_suspend in -lpthread... no checking for pthread_cancel in -lpthread... yes checking for pthread_condattr_setclock in -lpthread... no checking for pthread_setconcurrency in -lpthread... yes checking for pthread_yield in -lpthread... no checking for pthread_delay in -lpthread... no checking for pthread_delay_np in -lpthread... no checking for pthread_setschedprio in -lpthread... no checking for pthread_attr_setinheritsched in -lpthread... yes checking whether g++ supports -mt... no checking whether g++ supports -pthread... yes checking for numa_max_node in -lnuma... no

    Checking for functions: checking for uid_t in sys/types.h... yes checking for unistd.h... (cached) yes checking for working chown... yes checking for error_at_line... no checking for pid_t... yes checking vfork.h usability... no checking vfork.h presence... no checking for vfork.h... no checking for fork... yes checking for vfork... yes checking for working fork... yes checking for working vfork... (cached) yes checking whether lstat correctly handles trailing slash... no checking for sys/time.h... (cached) yes checking for unistd.h... (cached) yes checking for stdlib.h... (cached) yes checking for sys/param.h... (cached) yes checking for alarm... yes checking for working mktime... no checking for getpagesize... yes checking for working mmap... yes checking for working strnlen... yes checking for working strtod... yes checking whether closedir returns void... no checking for accept4... no checking for accept4 in -lposix4... no checking for accept4 in -lrt... no checking for accept4 in -lpthread... no checking for atexit... yes checking for daemon... yes checking for dup3... no checking for dup3 in -lposix4... no checking for dup3 in -lrt... no checking for dup3 in -lpthread... no checking for epoll_create1... no checking for epoll_create1 in -lposix4... no checking for epoll_create1 in -lrt... no checking for epoll_create1 in -lpthread... no checking for epoll_wait... no checking for epoll_wait in -lposix4... no checking for epoll_wait in -lrt... no checking for epoll_wait in -lpthread... no checking for epoll_ctl_batch... no checking for epoll_ctl_batch in -lposix4... no checking for epoll_ctl_batch in -lrt... no checking for epoll_ctl_batch in -lpthread... no checking for fallocate... no checking for fallocate in -lposix4... no checking for fallocate in -lrt... no checking for fallocate in -lpthread... no checking for fallocate64... no checking for fallocate64 in -lposix4... no checking for fallocate64 in -lrt... no checking for fallocate64 in -lpthread... no checking for fnmatch... yes checking for getaddrinfo... yes checking for getnameinfo... yes checking for getopt_long... yes checking for getpriority... yes checking for inet_ntop... yes checking for memmem... yes checking for memrchr... no checking for memrchr in -lposix4... no checking for memrchr in -lrt... no checking for memrchr in -lpthread... no checking for mkdtemp... yes checking for mremap... no checking for mremap in -lposix4... no checking for mremap in -lrt... no checking for mremap in -lpthread... no checking for pipe2... no checking for pipe2 in -lposix4... no checking for pipe2 in -lrt... no checking for pipe2 in -lpthread... no checking for posix_spawn... yes checking for pread... yes checking for sched_getaffinity... no checking for sched_getaffinity in -lposix4... no checking for sched_getaffinity in -lrt... no checking for sched_getaffinity in -lpthread... no checking for sem_init... yes checking for sem_getvalue... yes checking for sendfile... yes checking for sendfile64... no checking for sendfile64 in -lposix4... no checking for sendfile64 in -lrt... no checking for sendfile64 in -lpthread... no checking for strndup... yes checking for strptime... yes checking for strsignal... yes checking for strtof... yes checking for strtold... yes checking for strtoull... yes checking for gmtime_r... yes checking for timegm... yes checking for nanosleep... yes checking for strerror... yes checking for shm_open... yes

    C++ stuff: checking netinet6/in6.h usability... no checking netinet6/in6.h presence... no checking for netinet6/in6.h... no checking linux/in6.h usability... no checking linux/in6.h presence... no checking for linux/in6.h... no checking for inet_pton in -lc... yes checking for gethostbyname2 in -lc... yes checking if you want to enable build of examples... yes checking if you want to enable use of memory pool... yes checking if you want to enable Large File Support... yes checking if you want to enable use of coverage... no checking for compile with GCC optimizations flags enabled... yes checking if you want to enable mode final for build of ulib library... yes checking for use of the new linker flags... yes checking whether g++ supports -fvisibility-inlines-hidden... no checking for C/C++ restrict keyword... (cached) __restrict checking if you want to enable client response partial write support... no checking if you want to enable server check time between request for parallelization... no checking if you want to enable server captive portal mode... no checking if you want to enable server thread approach support... no checking if you want to enable HTTP inotify support... no checking if you want to enable client and server log support... no checking if you want to enable GDB stack dump support... no checking if you want to enable cache request support... yes checking if you want to enable homogeneous pipeline request support... yes checking if you want to enable HTTP/2 support... no checking if you want to enable server classic model support... no checking if you want to enable server bandwidth throttling support... no checking if you want to enable alias URI support... no checking if you want to enable welcome message support... no checking if you want to enable ACL filtering support... no checking if you want to enable RFC1918 filtering support... no checking if you want to enable HTTP Strict Transport Security support... no checking if you want to enable HTML pagination support... no checking if you want to enable use of bison/yacc... no checking if you want to use distcc... no checking whether g++ supports C++11 features by default... no checking whether g++ supports C++11 features with -std=c++11... yes checking whether std::chrono::steady_clock is available... yes checking whether std::future is available... yes

    Checking for libraries to link against: checking if LIBZ library is wanted... yes Cannot find LIBZ library checking if you want to enable build of ZIP support... no checking if tdb library is wanted... yes Cannot find libtdb library checking if zopfli library is wanted... yes Cannot find libzopfli library checking if libuuid library is wanted... yes Cannot find LIBUUID library checking if MAGIC library is wanted... yes Cannot find MAGIC library checking if SSL library is wanted... yes Cannot find SSL library checking if PCRE library is wanted... yes Cannot find PCRE library checking if EXPAT library for XML parsing is wanted... yes Cannot find EXPAT library checking if c-ares library for DNS resolution is wanted... yes Cannot find c-ares library checking if SSH library is wanted... no checking if cURL library is wanted... no checking if LDAP library is wanted... no checking if DBI library is wanted... no checking if libevent library is wanted... no checking if libxml2 library is wanted... no checking if you want to use page-speed SDK... no checking if you want to use V8 JavaScript Engine... no checking for SQLite3 support... no checking for MySQL support... no checking for PostgreSQL support... no

    Checking for libraries specific: checking for tcc_compile_string in -ltcc... no checking for GeoIP_id_by_ipnum in -lGeoIP... no checking for siginfo_t... yes checking for siginfo_t.si_addr... yes checking whether new ldflags are wanted... no checking if you want to use php-embedded... no checking if you want to use ruby-embedded... no checking for stdbool.h that conforms to C99... no checking for _Bool... no checking for uid_t in sys/types.h... (cached) yes checking for inline... (cached) inline checking for int16_t... yes checking for int32_t... yes checking for int64_t... yes checking for int8_t... yes checking for mode_t... yes checking for off_t... yes checking for pid_t... (cached) yes checking for C/C++ restrict keyword... (cached) __restrict checking for size_t... (cached) yes checking for ssize_t... yes checking for struct stat.st_blksize... yes checking for struct stat.st_blocks... yes checking for struct stat.st_rdev... yes checking for uint16_t... yes checking for uint32_t... yes checking for uint64_t... yes checking for uint8_t... yes checking for ptrdiff_t... yes

    Checking for structures: checking whether struct tm is in sys/time.h or time.h... time.h checking whether stat file-mode macros are broken... no checking for struct stat.st_blocks... (cached) yes checking for struct iphdr... no checking for struct dirent.d_reclen... yes checking for struct dirent.d_namlen... yes checking for struct tm.tm_gmtoff... yes

    Checking for types: checking for an ANSI C-conforming const... yes checking for size_t... (cached) yes checking for ptrdiff_t... (cached) yes checking size of unsigned char... 1 checking size of short... 2 checking size of int... 4 checking size of long... 8 checking size of time_t... 8 checking size of size_t... 8 checking size of long long... 8 checking size of __int64... 0 checking size of void *... 8 checking size of ptrdiff_t... 8 checking for cpu_set_t... no checking for working socket option SO_RCVTIMEO... no

    Checking for server plugin: checking server plugin "rpc"... dynamic checking server plugin "stream"... dynamic checking server plugin "nocat"... dynamic checking server plugin "socket"... dynamic checking server plugin "scgi"... dynamic checking server plugin "fcgi"... dynamic checking server plugin "ssi"... dynamic checking server plugin "tsa"... dynamic checking server plugin "http"... dynamic checking server plugin "echo"... dynamic checking loader.autoconf files... done

    Checking for ORM driver: checking loader.autoconf files... done checking for cpp... /usr/bin/cpp checking for mcpp... no checking for atomic... yes checking for doxygen... no checking for dlopen in -lc... yes checking strstream.h usability... no checking strstream.h presence... no checking for strstream.h... no checking determine if the kind of C++ iostream support is old... no

    Output Substitution:

    configure: Configured to build src/ulib/libulib:

          ULib version: 1.4.2
            Build ULib: Shared=yes, Static=yes
    
            Host setup: x86_64-apple-darwin15.0.0
        Install prefix: /usr/local
        Install plugin: /usr/local/libexec
    Configuration data: /usr/local/etc
    
      Operating System: Darwin Mac.local 15.0.0 Darwin Kernel Version 15.0.0: Wed Aug 26 16:57:32 PDT 2015; root:xnu-3247.1.106~1/RELEASE_X86_64 x86_64
          C++ Compiler: g++ (  )
                Linker: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld ( unknown )
    

    Standard C library: unknown Standard C++ library: unknown Libraries: -lpthread -lc

             C   Flags: -g -O2
             C++ Flags: -g -O2 -std=c++11 -fno-exceptions -fno-rtti
          Linker Flags: 
    Preprocessor Flags:  -D__OSX__ -D__APPLE__ -pthread -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
    
         debug support: no (--enable-debug)
      final build mode: enabled
    

    memory pool support: enabled LFS support: enabled ipv6 support: no (--with-ipv6) zip support: no (--enable-zip) thread support: enabled

          LIBZ support: no (--with-libz)
     LIBZOPFLI support: no (--with-libzopfli)
        LIBTDB support: no (--with-libtdb)
          PCRE support: no (--with-pcre)
           SSL support: no (--with-ssl)
           SSH support: no (--with-ssh)
          LDAP support: no (--with-ldap)
          cURL support: no (--with-curl)
           XML support: no (--with-expat)
         MAGIC support: no (--with-magic)
        SQLite support: no (--with-sqlite)
         MySQL support: no (--with-mysql)
         PgSQL support: no (--with-pgsql)
           DBI support: no (--with-libdbi)
       libuuid support: no (--with-libuuid)
      libevent support: no (--with-libevent)
       libxml2 support: no (--with-libxml2)
        c-ares support: no (--enable-libares)
    Page-Speed support: no (--with-page-speed)
    

    V8 JavaScript support: no (--with-v8-javascript) PHP language support: no (--with-php-embedded) RUBY language support: no (--with-ruby-embedded)

      Examples:         enabled
      LEX/YACC support: no (--with-parser)
      Lexical analyzer:  ( None )
      Parser generator:  ( None )
    

    See include/ulib/internal/config.h for further configuration information

    checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: creating rpm.sh config.status: creating ULib.spec config.status: creating m4/Makefile config.status: creating doc/Makefile config.status: creating include/Makefile config.status: creating contrib/Makefile config.status: creating src/ulib/Makefile config.status: creating src/ulib/ULib.rc config.status: creating src/ulib/ULib.pc config.status: creating src/ulib/orm/driver/Makefile config.status: creating src/ulib/net/server/plugin/Makefile config.status: creating src/ulib/net/server/plugin/v8/Makefile config.status: creating src/ulib/net/server/plugin/php/Makefile config.status: creating src/ulib/net/server/plugin/ruby/Makefile config.status: creating src/ulib/net/server/plugin/usp/Makefile config.status: creating src/ulib/net/server/plugin/mod_shib/Makefile config.status: creating src/ulib/net/server/plugin/mod_geoip/Makefile config.status: creating src/ulib/net/server/plugin/usp/usp_compile.sh config.status: creating src/ulib/net/server/plugin/page_speed/Makefile config.status: creating include/ulib/Makefile config.status: creating contrib/HCSP/Makefile config.status: creating contrib/RSIGN/Makefile config.status: creating contrib/signer/Makefile config.status: creating examples/Makefile config.status: creating examples/IR/Makefile config.status: creating examples/csp/Makefile config.status: creating examples/lcsp/Makefile config.status: creating examples/rsign/Makefile config.status: creating examples/hello/Makefile config.status: creating examples/WiAuth/Makefile config.status: creating examples/xml2txt/Makefile config.status: creating examples/uclient/Makefile config.status: creating examples/userver/Makefile config.status: creating examples/PEC_log/Makefile config.status: creating examples/workflow/Makefile config.status: creating examples/doc_parse/Makefile config.status: creating examples/lrp_session/Makefile config.status: creating examples/http_header/Makefile config.status: creating examples/test_manager/Makefile config.status: creating examples/doc_classifier/Makefile config.status: creating examples/form_completion/Makefile config.status: creating examples/simple_client_server/Makefile config.status: creating examples/download_accelerator/Makefile config.status: creating examples/XAdES/Makefile config.status: creating examples/XAdES/XAdES.spec config.status: creating examples/xml2txt/xml2txt.spec config.status: creating examples/IR/searchengine-bin.spec config.status: creating examples/lcsp/lcsp.spec config.status: creating examples/lcsp/lcsp_rpc.spec config.status: creating examples/csp/cspclient.spec config.status: creating examples/csp/cspclient_rpc.spec config.status: creating examples/rsign/rsignclient.spec config.status: creating examples/rsign/rsignclient_rpc.spec config.status: creating examples/userver/web_server.spec config.status: creating examples/userver/wagsmserver.spec config.status: creating examples/workflow/workflow.spec config.status: creating examples/PEC_log/PEC_log.spec config.status: creating examples/userver/tsaserver.spec config.status: creating examples/userver/cspserver.spec config.status: creating examples/userver/rsignserver.spec config.status: creating examples/doc_parse/doc_parse.spec config.status: creating tests/Makefile config.status: creating tests/base/Makefile config.status: creating tests/debug/Makefile config.status: creating tests/ulib/Makefile config.status: creating tests/examples/Makefile config.status: creating tests/contrib/Makefile config.status: creating include/ulib/internal/config.h config.status: executing depfiles commands config.status: executing libtool commands


    checking if generated configuration is usable... no

    opened by tkisme 5
  • Any chance of a tutorial ?

    Any chance of a tutorial ?

    Hello !

    The code only documentation does not give a clear way on how to use this library, any chance to have a tutorial or a sample application that works straight away ?

    I could not get anything to work due to missing configuration, it doesn't seem to have default configuration.

    I installed to a custom location $HOME/local/ulib .

    Cheers !

    opened by mingodad 5
  • For real world practical usage's docker container

    For real world practical usage's docker container

    I'm ready to take the next step to explore in greater detail but I'm having problem with some of the configuration settings. I'm using Ubuntu 16.04 docker container. Can you please provide the instructions to compile / configure for these options inside the docker container? It took me quite some time and I can't seem to make "some useful ones" work.

    Will really appreciate if you can provide the ./configure (for real world application these settings)

    1. --with-mysql
    2. --with-mongodb
    3. --enable-http2
    4. --enable-HIS
    5. --enable-throttling (not sure what is this for? cache?)
    6. --enable-evasive (good to have but quite optional for me)
    7. --enable-curl (good to have)
    8. --with-ssh (for the cookie.usp? cant seem to get this right)
    9. --with-v8-javascript (for testing purposes)
    10. --with-ssl (for cookie.usp?)

    these are the very real world practical example. Hope to deploy a case studies and help speed up the development of this. Appreciate it. I would like to run a few .usp examples inside for serious real world work asap... Thanks in advance.

    opened by unisqu 4
  • extensive documentation?

    extensive documentation?

    Hello!

    May I suggest you to write extensive documentation?

    I'm a little familiar with (python) Flask web microframework. It alone has extensive User Guide, with lots of example code, and advice. Beginning with "Quickstart" (kind of advertising overview), then Tutorial, then covering standard tools, then advanced issues, and eventually, API. Look at it, it's a great example of documentation. Each module Flask is usually used with (like login, forms, templates, database, etc) also has similar extensive documentation.

    Same with nginx: lots of documentation, examples, FAQs, (official) blog posts.

    For ulib, I only see a very short wiki (by jonathan kelly). For such a huge project (much larger than Flask), only a short "getting started"?!

    Examples are great, but, in my perhaps not very humble opinion, there should be an intermediate-level documentation: use cases with key code excerpts.

    Suppose you die. Will this great kid of yours continue to live its life on its own?

    What do you think?

    opened by blue-apparition 1
  • LiteSpeed Web ADC alternative, just QUIC + loadbalancing proxy based on ip hash

    LiteSpeed Web ADC alternative, just QUIC + loadbalancing proxy based on ip hash

    ULib is fantastic. Good work on the quic direction. The market needs an ADC like litespeed. If ULib can get just a

    1. basic auto letsencrypt ssl QUIC terminator (frontend), no need any setup, autocertbot
    2. proxy loadbalancing based on ip hash / round robin / backup

    the above 2 will greatly increase adoption and can start to operate as a business like litespeed. there is no such thing in the market and ULib is one of the best software to fill this area. Afterall, ADC like litespeed is an area ULib can really shine (coz of their insane pricing @ 5 figures for enterprise version)

    I'm willing to help set up the website / make it into a business, become one of the partner/ reseller if possible too.

    opened by gitmko0 1
  • Regular USP files don't work when --enable-captive-portal is set

    Regular USP files don't work when --enable-captive-portal is set

    Hi,

    I have been playing around with ULib after seeing how impressive the performance was on the Techempower benchmarks, and I was trying to see what the performance is like while using a more standard .usp file instead of the hyper-optimized version used in the Techempower tests. However when I try it using the same docker configuration used in the Techempower test, my simple .usp file does not work e.g.

    <!--#header
    Content-Type: text/plain
    -->
    Hello, World!
    

    Then I run curl against the endpoint this is the response that I get:

    [email protected]:/# curl -v http://server/plain
    *   Trying xxx.xxx.xxx.xxx...
    * TCP_NODELAY set
    * Connected to server (xxx.xxx.xxx.xxx) port 8080 (#0)
    > GET /plain HTTP/1.1
    > Host: server:8080
    > User-Agent: curl/7.58.0
    > Accept: */*
    >
    < HTTP/1.1 200 OK
    < Date: Mon, 27 Apr 2020 01:27:23 GMT
    < Server: ULib
    < Content-Type: text/plain
    * no chunk, no close, no size. Assume close to signal end
    <
    

    And the body is not returned. I looked at the code and played around with the feature flags until I realized which one was causing the problem. When --enable-captive-portal is used, simple .usp files no longer work, but the techempower optimized ones do. Is this a bug?

    This is the configure command that I used in my test:

    RUN ./configure --prefix=$ULIB_ROOT \
        --disable-static --disable-examples --disable-plugins \
        --disable-log --disable-alias --enable-captive-portal \
        --without-ssl --without-pcre --without-expat \
        --without-libz --without-libuuid --without-magic --without-libares \
        --without-libzopfli --without-libbrotli \
    	--enable-static-server-plugin=http
    

    When I remove --enable-captive-portal from the configure command, .usp files work again, but performance of the optimized json and plaintext examples drops by about 30%

    opened by talawahtech 3
Releases(v2.4.2)
Owner
stefano casazza
stefano casazza
C library to create simple HTTP servers and Web Applications.

Onion http server library Travis status Coverity status Onion is a C library to create simple HTTP servers and Web Applications. master the developmen

David Moreno Montero 1.9k Aug 10, 2022
TreeFrog Framework : High-speed C++ MVC Framework for Web Application

Small but Powerful and Efficient TreeFrog Framework is a high-speed and full-stack web application framework based on C++ and Qt, which supports HTTP

TreeFrog Framework 1.1k Aug 7, 2022
Tntnet is a web application server for web applications written in C++.

Tntnet is a web application server for web applications written in C++.

Tommi Mäkitalo 72 Aug 1, 2022
Corvusoft's Restbed framework brings asynchronous RESTful functionality to C++14 applications.

Restbed Restbed is a comprehensive and consistent programming model for building applications that require seamless and secure communication over HTTP

Corvusoft 1.7k Aug 6, 2022
🌱Light and powerful C++ web framework for highly scalable and resource-efficient web application. It's zero-dependency and easy-portable.

Oat++ News Hey, meet the new oatpp version 1.2.5! See the changelog for details. Check out the new oatpp ORM - read more here. Oat++ is a modern Web F

Oat++ 5.6k Aug 11, 2022
Drogon: A C++14/17 based HTTP web application framework running on Linux/macOS/Unix/Windows

English | 简体中文 | 繁體中文 Overview Drogon is a C++14/17-based HTTP application framework. Drogon can be used to easily build various types of web applicat

An Tao 7.7k Aug 4, 2022
Your high performance web application C framework

facil.io is a C micro-framework for web applications. facil.io includes: A fast HTTP/1.1 and Websocket static file + application server. Support for c

Bo 1.6k Aug 2, 2022
The application framework for developer module of EdgeGallery platform

crane-framework crane-framework将可复用的计算和软件功能抽象成插件,APP开发者面向使用插件进行MEC APP开发。这样屏蔽了和MEC平台交互的细节,实现MCE APP和MEC平台的松耦合。而且插件框架基础能力可裁剪,按需提供最小的APP系统。 特性介绍 为了方便开发者

EdgeGallery 21 Aug 30, 2021
A C++ Web Framework built on top of Qt, using the simple approach of Catalyst (Perl) framework.

Cutelyst - The Qt Web Framework A Web Framework built on top of Qt, using the simple and elegant approach of Catalyst (Perl) framework. Qt's meta obje

Cutelyst 779 Aug 3, 2022
A Zig binding to the webview library. Make Zig applications with a nice HTML5 frontend a reality!

A Zig binding to the webview library. Make Zig applications with a nice HTML5 frontend a reality!

ZigLibs 35 Aug 1, 2022
Pistache is a modern and elegant HTTP and REST framework for C++

Pistache is a modern and elegant HTTP and REST framework for C++. It is entirely written in pure-C++17* and provides a clear and pleasant API.

null 2.7k Aug 7, 2022
Crow is very fast and easy to use C++ micro web framework (inspired by Python Flask)

Crow is C++ microframework for web. (inspired by Python Flask) #include "crow.h" int main() { crow::SimpleApp app; CROW_ROUTE(app, "/")([]()

Jaeseung Ha 6.9k Aug 2, 2022
This is a proof-of-concept of a modern C web-framework that compiles to WASM and is used for building user interfaces.

DanCing Web ?? ?? (DCW) Getting Started Dancing Web is now distributed with the Tarantella Package Manager — a tool I've made to simplify setup of pro

Danilo Chiarlone 3 Sep 11, 2021
QDjango, a Qt-based C++ web framework

QDjango - a Qt-based C++ web framework Copyright (c) 2010-2015 Jeremy Lainé About QDjango is a web framework written in C++ and built on top of the Qt

Jeremy Lainé 245 Aug 5, 2022
A http/websocket server framework on linux.

The framework is a Web-Server on unix based system. Without using any third-party libraries, the framework writes from unix system calls and standard C library functions.

xingyuuchen 16 Jun 11, 2022
CppCMS - High Performance C++ Web Framework

CppCMS - High Performance C++ Web Framework What is CppCMS? CppCMS is a Free High Performance Web Development Framework (not a CMS) aimed at Rapid Web

Artyom Beilis 365 Aug 2, 2022
A high performance, middleware oriented C++14 http web framework please use matt-42/lithium instead

A high performance, middleware oriented C++14 http web framework please use matt-42/lithium instead

Matthieu Garrigues 1.7k Aug 2, 2022
C++ Parallel Computing and Asynchronous Networking Engine

中文版入口 Sogou C++ Workflow As Sogou`s C++ server engine, Sogou C++ Workflow supports almost all back-end C++ online services of Sogou, including all sea

Sogou-inc 8.9k Aug 8, 2022