Permalink
Commits on Mar 21, 2012
  1. Test is handle_open is defined in the CallbackMod.

    Signed-off-by: François de Metz <francois@stormz.me>
    committed Mar 21, 2012
Commits on Mar 16, 2012
  1. Add doc.

    Signed-off-by: François de Metz <francois@stormz.me>
    committed Mar 16, 2012
  2. Rename handle_message/2 by handle_open/1.

    Signed-off-by: François de Metz <francois@stormz.me>
    committed Mar 16, 2012
  3. Fix the unused param.

    Signed-off-by: François de Metz <francois@stormz.me>
    committed Mar 16, 2012
  4. Websocket open callback.

    We can now pass some parameters when upgrading to websockets.
    
        {websockets, CallbackMode, Opts, Params}
    
    When the connection is upgraded, the websocket module now call:
    
        CallbackMode:handle_message(open, Params)
    
    Which allows you to keep some parameters from the initial request.
    On the open callback, you can also send date over the connection.
    
        handle_message(open, _Params) ->
            yaws_api:websocket_send(self(), {text, <<"Hello world">>}).
    
    TODO:
    
      * handle compatibility with the previous implementation
      * should we handle return value? Like {close, Reason}?
      * update doc
      * add tests
      * gather feedback
    
    Signed-off-by: François de Metz <francois@stormz.me>
    committed Mar 16, 2012
Commits on Mar 6, 2012
  1. Update gitignore file

    capflam committed Mar 6, 2012
  2. Fix bug when reentrant requests are used to return regular files

    Response headers were not correctly set, in particular the Content-Length
    header. This bug was fixed by refactoring the way reentrant requests are
    handled.
    capflam committed Mar 6, 2012
Commits on Mar 5, 2012
  1. Merge pull request #94 from karlsson/master

    Adapted yapp.app.src to new yaws include.mk
    vinoski committed Mar 5, 2012
Commits on Mar 4, 2012
Commits on Feb 28, 2012
Commits on Feb 27, 2012
Commits on Feb 24, 2012
  1. Add the revproxy testsuite

    capflam committed Feb 24, 2012
Commits on Feb 21, 2012
  1. Refactor the reverse proxy to manage it as a "special" appmod

    Now, the reverse proxy is written like an appmod and follows the same
    workflow. We forge the #urltype{} record and use Arg#arg.state to pass
    the revproxy's rule before calling yaws_revproxy:out/1.
    
    For now, the support of persistent connections with the backend servers
    is disabled. But it does not affect the status of client connections.
    Chunked-transfer encoded requests and responses are supported.
    
    Despite this refactoring, yaws_revproxy is always experimental and need
    more tests to be safely used in production environments.
    capflam committed Feb 21, 2012
  2. Manage all 'special' headers of #headers{} and #outh{} records

    Some headers, like 'Content-Encoding' or 'Transfer-Encoding' were
    not correctly handled. These changes can be useful for everyone who
    writes yaws scripts or appmods. In particular, the next version of
    the reverse proxy depends on it.
    capflam committed Feb 21, 2012
Commits on Feb 17, 2012
  1. clean up rebar build problems with examples/src

    Clean up some duplicate options and extra whitespace in
    examples/src/Makefile, and add examples/src to rebar.config to make
    sure it gets built under rebar.
    vinoski committed Feb 17, 2012
Commits on Feb 15, 2012
  1. Fix issue #88

    2 changes here:
    
     * Revert "Flush remaining data when dynamic content is delivered"
    
    This reverts commit d09ed3d.
    Systematically flushing data is not a good idea.
    
     * Add "flush" as possible return value of the out/1 function
    
    Some clients (eg. Firefox and google-chome...) do not handle connection
    close gracefully when the connection is closed during sending data; they
    do not read the server response. So, when the response is important, to
    warn the end-user that an error occured for example, we must be fair by
    flushing data before closing the connection.
    capflam committed Feb 15, 2012
Commits on Feb 13, 2012
  1. Fixed issue 87

    klacke committed Feb 13, 2012
Commits on Feb 12, 2012
  1. add close callback for websockets

    WebSocket clients can close their end of the connection, and RFC 6455
    requires servers to handle that message appropriately. This change
    adds a new callback message for basic WebSocket callback modules. The
    server now also replies to client "close" messages with a "close"
    reply, as RFC 6455 requires. WebSockets documentation updated as well.
    
    Also included a message ordering fix from Jan Bothma.
    vinoski committed Feb 10, 2012
Commits on Feb 10, 2012
  1. minor cleanup

    vinoski committed Feb 10, 2012
Commits on Feb 2, 2012
  1. Allow the server signature to be defined per virtual server

    Now, we can use the 'server_signature' directive into the server part
    to overload the global one for specific virtual server.
    capflam committed Feb 2, 2012
Commits on Jan 24, 2012
Commits on Jan 23, 2012
  1. rotate log file regardless of copy_errlog parameter

    Signed-off-by: Garret Smith <garret.smith@gmail.com>
    garret-smith committed Dec 7, 2011
  2. fix log rotation on Windows, where fsync() is required to get the act…

    …ual file size
    
    Signed-off-by: Garret Smith <garret.smith@gmail.com>
    garret-smith committed Dec 7, 2011
Commits on Jan 20, 2012
  1. Simplify excl_sys_filters

    tuncer committed Jan 20, 2012
Commits on Jan 18, 2012
  1. fixed wiki app XSS vulnerabilities

    In applications/wiki/src/wiki.erl,
    applications/wiki/src/wiki_format_txt.erl,
    applications/wiki/src/wiki_to_html.erl: Fixed CVE-2011-5025 (multiple
    cross-site scripting (XSS) vulnerabilities in the wiki) by accepting
    only letters and digits in node names, guarding a few calls to
    list_to_integer/1, and escaping all HTML which goes to a user's
    browser.
    sgolovan committed with vinoski Jan 16, 2012
  2. R15B compatibility fixes

    In applications/mail/src/mail.erl, applications/mail/src/smtp.erl,
    applications/wiki/src/utils.erl, applications/wiki/src/wiki.erl,
    applications/wiki/src/wiki_format_txt.erl,
    applications/wiki/src/wiki_yaws.erl: Fixed compatibility with Erlang
    R15B. Replaced atom/1, list/1, integer/1 by is_atom/1, is_list/1,
    is_integer/1 and erlang:fault/1 by erlang:error/1. In the wiki app,
    replaced regexp module by re one, renamed error/1 by html_error/1 to
    avoid clashing with global error/1 function.
    sgolovan committed with vinoski Jan 16, 2012
  3. fix syntax and spelling errors in man pages

    In man/yaws.conf.5, man/yaws_api.5: Fixed a few syntax and spelling
    errors in manpages.
    sgolovan committed with vinoski Jan 16, 2012
  4. handle parseable but invalid ctlfile

    src/yaws_ctl.erl: Process the case when ctlfile is parseable but its
    content is invalid.
    sgolovan committed with vinoski Jan 16, 2012
  5. fixes for make clean in applications and doc dirs

    * applications/wiki/scripts/Makefile: Remove all scripts on make
      clean.
    * applications/yapp/Makefile: Remove forgotten PNG image on make
      clean.
    * doc/Makefile: Remove generated www/yaws.ps and www/yaws.pdf on
      make clean.
    sgolovan committed with vinoski Jan 16, 2012
Commits on Jan 9, 2012
  1. Merge remote-tracking branch 'capflam/trace_improvements'

    Conflicts:
    	src/yaws_server.erl
    klacke committed Jan 9, 2012