Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Oct 1, 2012
  1. @vinoski
Commits on Sep 18, 2012
  1. @capflam
  2. @capflam

    Parse extensions and trailing headers of chunked transfer encoded req…

    capflam authored
    …uests
    
    Chunk extensions and trailing headers are parsed but ignored in requests
    and are not supported in responses. It is a strange feature of the RFC-2619
    and would be hard to implement. Moreover, this feature is rarely supported
    by clients and servers and even less used.
    So, without any concrete use-case, no further work will be done on this
    subject.
  3. @capflam
  4. @capflam

    Optimize the ACL checks during the request's authentication

    capflam authored
    Now, in yaws_server:handle_auth/4, the client ip is no more converted into
    integer. All ip addresses in #auth.acl are of the type ip_address(). That makes
    easier the checking of the client ip.
    To clean up the code, functions that parses and checks the allowed/denied ip
    addresses with the client ip were moved into yaws.erl.
Commits on Sep 10, 2012
  1. Added support to configure ciphers in ssl, previously the ciphers = V…

    authored
    …al stricng in yaws.conf required the Val to be a string according the openssl cipher string spec language. Now we specify an erlang list instead, the list shall comply to the output of ssl:cipher_suites()
Commits on Sep 9, 2012
  1. @vinoski
Commits on Sep 8, 2012
  1. Merge pull request #124 from jj1bdx/jj1bdx-dialyzer-fix

    authored
    Update Makefile and src/Makefile
  2. @jj1bdx

    Update Makefile and src/Makefile

    jj1bdx authored
    * Targets in `Makefile` of `yaws.plt` and `dialyzer` calls
      dialyzer with two target directories, `ebin` and `src`;
      this causes the error of duplicate modules.
      Checking out the .beam files under `ebin` is sufficient
      for dialyzer; `src` is removed.
    
    * Target `mime_type_c.beam` in `src/Makefile` is
      superfluous and generates a spurious .beam file in
      the `src` directory, so the target is removed.
      Also target `charset.def` in `src/Makefile` should be
      dependent on `../ebin/mime_type_c.beam`, so this is
      also changed from the previous target without the
      directory path.
Commits on Sep 1, 2012
  1. @vinoski

    update mime.types file

    vinoski authored
Commits on Aug 26, 2012
  1. @vinoski

    add startup script for FreeBSD 9 (Thomas Elsgaard)

    vinoski authored
    Add scripts/freebsd/yaws for FreeBSD version 9 or later. The original
    script at scripts/freebsd/yaws.sh is retained for use with FreeBSD versions
    prior to 9.
Commits on Aug 25, 2012
  1. @vinoski

    make sure "rebar eunit" passes

    vinoski authored
    When using yaws as an app dependency for another application built with
    rebar, I noticed that testing that application with "rebar eunit" would
    fail while testing yaws. It was easy to work around with "rebar eunit
    skip_deps=true" but yaws really should pass its tests when tested via
    rebar.
    
    Change rebar.config to add ibrowse as a dependency. It's used only for
    testing, but rebar doesn't support test-only dependencies, plus it's
    filtered out during release generation anyway.
    
    Modify some of the test files to be able to find ibrowse include files
    regardless of whether they're built via make or via rebar. Also rename all
    non-eunit test functions ending in "_test" so they don't confuse eunit. Also
    had to move the embedded_yaws_id_dir test from eunit to t2 because it fails
    under "rebar eunit" when yaws is a dependency for another app. It fails
    because it calls into the yaws_api:embedded_start_conf function which tries
    to call application:load(yaws), but paths aren't properly set up to allow
    that to work under these testing circumstances.
    
    Note that not all tests currently run under rebar; building with make and
    then running "make test" results in many more tests being executed. Fixing
    this will come later.
Commits on Aug 24, 2012
  1. @vinoski

    revert commit d990b30

    vinoski authored
    Commit d990b30 was intended to fix issue #122 but my testing was flawed, so
    I'm reverting it. The real issue seems to be a bug with reltool not
    honoring app overrides of sys-level mod_cond settings.
  2. @vinoski

    make sure more modules are included in a release (issue #122)

    vinoski authored
    The problem that caused issue #122 is that the yaws_outmod module, which
    isn't directly referenced by any other yaws module, was not being included
    in the application release. Change the mod_cond in rel/reltool.config to
    all rather than app to ensure yaws_outmod gets included.
Commits on Aug 23, 2012
  1. @vinoski
Commits on Aug 22, 2012
  1. @vinoski

    add flexible variant of yaws_api:reformat_header

    vinoski authored
    Add a new yaws_api:reformat_header/2 that takes a formatting function as
    the second argument. The old reformat_header/1 now just calls this, passing
    the original formatting function.
Commits on Aug 7, 2012
  1. @vinoski

    Merge pull request #121 from jbothma/master

    vinoski authored
    Add basic websocket test.
  2. @vinoski
Commits on Aug 6, 2012
  1. @vinoski
Commits on Jul 30, 2012
  1. @jbothma

    Add basic websocket test.

    jbothma authored
    It performs the handshake, then sends one text message and checks
    that it is echoed back correctly.
Commits on Jul 26, 2012
  1. @capflam

    Improve how Yaws is started in embedded mode

    capflam authored
    The main change concerns the function yaws:create_sconf/2. Now, this function
    relies on yaws_config:make_default_sconf/2 to create a default #sconf record.
  2. @capflam
Commits on Jul 25, 2012
  1. @capflam

    Make the mime types mappings configurable

    capflam authored capflam committed
    Now, it possible to customize the global mime types mappings and to overload
    it for each virtual server. It can be done using following directives in the
    global part or the server part of the configuration:
    
    * default_type: Defines the default mime type to be used where Yaws cannot
      determine it by its mime types mappings (default: text/plain).
      In the server part, this directive overloads the global one.
    
    * default_charset: Defines the default charset to be added when a response
      content-type is text/* (default: none). In the server part, this directive
      overloads the global one.
    
    * mime_types_file: Overrides the default mime.types file included with Yaws
      (default: ${PREFIX}/lib/yaws/priv/mime.types). In the server part, this
      directive overloads the global one but mappings defined in this file will
      not overload those defined by add_types directives in the global part.
    
    * add_types: Specifies one or more mappings between mime types and file
      extensions. More than one extension can be assigned to a mime type. If a
      mapping is defined in the global part and redefined in a server part using
      this directive, then the later is used. Else the global one is kept.
    
    * add_charsets: Specifies one or more mappings between charsets and file
      extensions. More than one extension can be assigned to a charset. If a
      mapping is defined in the global part and redefined in a server part using
      this directive, then the later is used. Else the global one is kept.
    
    Here is an example:
    
      default_type = text/html
    
      <server localhost>
          port = 8000
          listen = 0.0.0.0
          docroot = /var/www
          # nothing is overloaded in the vhost
      </server>
    
      <server localhost>
          port = 8001
          listen = 0.0.0.0
          docroot = /var/www
    
          # overload global configuration:
          default_type    = text/plain
          mime_types_file = /etc/mime.types
          add_types       = <text/xhtml, yaws> <application/x-test, tst test>
          default_charset = UTF-8
          add_charsets    = <ISO-8859-1, php html yaws> <US-ASCII, tst>
      </server>
    
    During Yaws compilation, a default module 'mime_types' is created using the
    default mime.types file. Then, when yaws starts up, this module is
    re-generated, re-compiled and loaded dynamically. The new module replaces the
    default one but the .beam file is unchanged. So if one of these steps failed,
    we fall back on the default module.
Commits on Jul 24, 2012
  1. @capflam
Commits on Jul 14, 2012
  1. @vinoski

    Merge pull request #117 from tuncer/noderunner

    vinoski authored
    Sync rel/files/yaws with upstream template
Commits on Jul 13, 2012
  1. @tuncer
  2. Merge pull request #116 from sumup/feature/soap12_imports_namespaces

    authored
    Feature/soap12 imports namespaces
Commits on Jul 12, 2012
  1. @vinoski
Commits on Jul 11, 2012
  1. @capflam

    Add index_files directive into the server part configuration

    capflam authored
    This directive sets the list of resources to look for, when a directory is
    requested by the client. If the last entry begins with a "/", and none of
    the earlier resources are found, Yaws will perform a redirect to this uri.
    
    Default is:
      index_files = index.yaws index.html index.php
Commits on Jul 10, 2012
  1. @vinoski

    wrap SSL sockets in tuple

    vinoski authored
    Yaws previously internally used details of an SSL socket representation
    that's supposed to be private/opaque to Erlang's SSL support. Encapsulate
    SSL sockets within a {ssl, SslSocket} tuple and add the
    yaws_api:get_sslsocket/1 function that returns a socket for SSL sockets or
    undefined for non-SSL sockets. Also document the new get_sslsocket/1
    function and other minor tweaks to SSL areas of the documentation.
  2. @vinoski

    minor changes to server-sent events

    vinoski authored
    Change yaws_sse to send close connection header by default, and change the
    example to return an Allow header if anything other than GET is requested.
  3. @capflam
  4. @capflam

    Refactor Set-Cookie/Cookie header parsing to follow RFC6265

    capflam authored
    RFC6265 obsoletes RFC2965 and RFC2109. #setcookie{} and #cookie{} are
    changed to reflect this new RFC. So, yaws_api:parse_set_cookie/1 and
    yaws_api:parse_cookie/1 are refactored accordingly:
    
    * yaws_api:parse_set_cookie/1: Because RFC2109 and RFC2965 are still used,
      we try to be backward compatible with these old RFCs. So this function
      returns a #setcookie{} record when only one cookie is found else it returns
      a list of #setcookie{} records.
      in RFC2109 and RFC2965, cookies are separated by comma. So, comma is
      forbidden in 'path-av' and 'extension-av' except for double-quoted value.
      The parsing are not really strict because of the compatibility and can lead
      to unwanted behaviors.
      Old attributes (like 'Comment' or 'Port') are still parsed and can be
      found into #setcookie.extensions field.
    
    * yaws_api:parse_cookie/1: This function follows the RFC6265, so all cookie
      attributes (like '$Domain' or '$Path') are parsed like any other cookie.
Commits on Jul 9, 2012
  1. @kdcircle
Something went wrong with that request. Please try again.