Dashboard

whitespace changes

    • -19
    • +19
    /openacs-4/packages/acs-tcl/tcl/html-procs.tcl
modernize code

moved long time deprecated function "ad_approval_system_inuse_p" to deprecated-procs

    • -18
    • +1
    /openacs-4/packages/acs-tcl/tcl/admin-procs.tcl
Improved comments and make code more robust in regards of legacy setups

Added support for relative redirects

RFC 2616 requires an absolute URI in the "Location" header field. So

if someone calls "ns_returnredirect /", NaviServer transforms it on

the fly into an absolute URL by prefixing it with the location

(e.g. https://openacs.org/). NaviServer (and OpenACS) has some complex

code to compute the location value, especially when virtual servers

are involved (or for "host-node mapped" subsites in OpenACS). The

situation is further complicated when running behind a reverse proxy

and/or in a containerized environment. In such cases, the location is

computed from the "host" request header field, which must be

validated, otherwise an attacker could hijack a session and redirect

it to a spoofed site.

The situation changed 10 years ago (June 2014) with the introduction

of RFC 7231, which allows relative redirects (see

https://www.rfc-editor.org/rfc/rfc7231#section-7.1.2). Using relative

redirects greatly simplifies configuration and closes the attack

vector using the host header field. RFC 7231 has been superseded by

RFC 9110 (June 2022), which also supports relative redirects via the

"location" response header field (see

https://www.rfc-editor.org/rfc/rfc9110#field.location).

Since OpenACS prefixed always the URL with a location, when it

encounters are relative URL in a "ad_returnredirect", this change

makes use of the new feature of NaviServer 5.

Make sure to use a current version of NaviServer, where the support

was added recently.

Document more explicitly that we do not perform filesystem operations when deleting files via the fs:: api, but we rely on the content repository and its trigger+scheduled proc mechanism

Document behavior: the assumption that one can derive the filename from the api is not correct in case of copies

Revert https://cvs.openacs.org/changelog/OpenACS?cs=oacs-5-10%3Aantoniop%3A20240423144330

currently, file-storage will copy files by simply copying the revision entry of the new file from the original one. This means that copied files will in fact point to the same filesystem file of the original.

This "works" because the file-storage api will currently never delete a file from the filesystem, so deleting the original file will not affect the copies.

This behavior is probably not ideal, but we won't address it before the release, as to change it will most likely require some careful planning, in particular for existing installations.

improved robustness during bootstrap

improved speling

improved spelling

updated jqueryui to latest version

improved spelling

bumped version numbers due to upstream releases

Extended "ad_conn behind_secure_proxy_p"

This test will be now true, when either the recieved request

contains one of those request header fields.

- "X-SSL-Request: 1"

- "X-Forwarded-Proto: https"

Before, only the first variant was accepted.

The AWS load balancer uses the second variant.

whitespace changes

Fixed potential infinie loop when source code looks like an regexp call

The api-code prettifier contains several heuristics for prettifying

source code without being a proper parser. It contains a

"Hack for nasty regexp stuff" which could run potentially into an infinite

parsing loop. This change fixes an acutal bug on openacs.org for file [1]

which is site-local.

[1] https://openacs.org/api-doc/procs-file-view?path=packages/xowf/tcl/openacs-procs.tcl&version_id=5526548&source_p=1

fix typo

Permit "lang::message::cache" in acs::clusterwide operations

improvement for ACS clusters

Incorporated changes as suggested by Jonathan Kelley

For details, see https://openacs.org/forums/message-post?parent_id=5814308

Base "ad_conn behind_proxy_p" on "ns_conn details" when available

Inject a reference to the current connection package into the tinymce conf (when used outside of xowiki)

Fix file metadata

Provide a reference to the current object when configuring tinymce

Allow to completely override the imageSelectorDialog URL downstream

Fix typo

Don't trigger the "too long without artifacts" timeout in case we are just doing dummy uploads

Fallback to the editor from parameter in the generic api, rather than the widget, so fallback will work also outside of ad_form

Introduce for richtext editors the concept of "preset"

A preset is an abstract set configurations designed to address a specific use case.

An example could be a preset for a "minimal" richtext editor, used in those forms where we want to limit the features a user should have access to. Other presets could address specific usages or applications.

Downstream developers can provide a set of ::richtext::$editor::preset::$preset procs, returning an options dict. This set of options will be merged other local configurations.

The same approach works in ad_forms and xowiki forms.

This also enables the use-case of switching to a different editor maintaining the existing application-specific configurations consistent.

Drop the old approacs based on ::acs_blank_master__htmlareas and use explicit id configuration