security::get_insecure_location (private)

 security::get_insecure_location

Defined in packages/acs-tcl/tcl/security-procs.tcl

Return the current location in insecure mode (http).

Author:
Peter Marklund

Partial Call Graph (max 5 caller/called nodes):
%3 test_get_insecure_location get_insecure_location (test acs-tcl) security::get_insecure_location security::get_insecure_location test_get_insecure_location->security::get_insecure_location apm_package_id_from_key apm_package_id_from_key (public) security::get_insecure_location->apm_package_id_from_key parameter::get parameter::get (public) security::get_insecure_location->parameter::get security::get_http_port security::get_http_port (private) security::get_insecure_location->security::get_http_port util::join_location util::join_location (public) security::get_insecure_location->util::join_location util::split_location util::split_location (public) security::get_insecure_location->util::split_location security::get_insecure_qualified_url security::get_insecure_qualified_url (private) security::get_insecure_qualified_url->security::get_insecure_location

Testcases:
get_insecure_location
Source code:
    set current_location [util_current_location]
    set http_prefix {http://}

    if { [string match "$http_prefix*" $current_location] } {
        #
        # Current location is already insecure - do nothing
        #
        set insecure_location $current_location
    } elseif {[util::split_location $current_location proto hostname port]} {
        #
        # Do not return a location with a port number, when
        # SuppressHttpPort is set.
        #
        set suppress_http_port [parameter::get -parameter SuppressHttpPort  -boolean  -package_id [apm_package_id_from_key acs-tcl]  -default 0]
        set insecure_location [util::join_location  -proto http  -hostname $hostname  -port [expr {$suppress_http_port ? "" : [security::get_http_port]}]]
    } else {
        error "invalid location $current_location"
    }

    return $insecure_location
Generic XQL file:
packages/acs-tcl/tcl/security-procs.xql

PostgreSQL XQL file:
packages/acs-tcl/tcl/security-procs-postgresql.xql

Oracle XQL file:
packages/acs-tcl/tcl/security-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: