Plugin Directory

Changeset 511077


Ignore:
Timestamp:
02/27/2012 12:52:40 PM (14 years ago)
Author:
glatze
Message:

New Links to bugtracker in readme.txt

Location:
active-directory-integration/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • active-directory-integration/trunk/ad-integration.php

    r489381 r511077  
    44Plugin Name: Active Directory Integration
    55Version: 1.1.3
    6 Plugin URI: http://blog.ecw.de/wp-ad-integration
     6Plugin URI: http://www.steindorff.de/wp-ad-integration
    77Description: Allows WordPress to authenticate, authorize, create and update users through Active Directory
    8 Author: Christoph Steindorff, ECW GmbH
    9 Author URI: http://blog.ecw.de/
     8Author: Christoph Steindorff
     9Author URI: http://www.steindorff.de/
    1010
    1111The work is derived from version 1.0.5 of the plugin Active Directory Authentication:
     
    228228    protected $_prevent_email_change = false;
    229229   
    230     // protected $_auto_login = false; // TODO: for auto login/SSO feature, has to be added to _load_options(), admin.php etc.
     230    // protected $_sso_enabled = false; // TODO: for auto login/SSO feature, has to be added to _load_options(), admin.php etc.
    231231       
    232232
     
    565565        register_setting('ADI-auth-settings', 'AD_Integration_authorize_by_group', array(&$this, 'sanitize_bool'));
    566566        register_setting('ADI-auth-settings', 'AD_Integration_authorization_group');
    567         register_setting('ADI-auth-settings', 'AD_Integration_role_equivalent_groups');
     567        register_setting('ADI-auth-settings', 'AD_Integration_role_equivalent_groups', array(&$this, 'sanitize_role_equivalent_groups'));
    568568       
    569569        // Security
     
    16261626   
    16271627    /**
     1628     * Strips out wrong entries from role_equivalent_groups and converts the WP role to lowercase.
     1629     *
     1630     * @param string $text
     1631     * @return string
     1632     */
     1633    public function sanitize_role_equivalent_groups($text)
     1634    {
     1635        $groups = explode(";", $text);
     1636        $sanitized_groups = array();
     1637        foreach ($groups AS $group) {
     1638            $group = trim($group);
     1639            $pos = strpos($group, '=');
     1640            if ($pos != 0) { // yes != 0, since int 0 is also unwanted
     1641                $ad_group = substr($group,0,$pos);
     1642                $role = strtolower(substr($group,$pos+1)); // roles are always lowercase
     1643                if ($role != '') {
     1644                    $sanitized_groups[] = $ad_group . '=' . $role;
     1645                }
     1646            }
     1647        }
     1648        return implode(";", $sanitized_groups);
     1649    }       
     1650   
     1651    /**
    16281652     * Sanitize Additional User Attributes
    16291653     * trim, delete empty line, all to lowercase.
     
    25432567            if ( $role != '' )
    25442568            {
    2545                 $return = wp_update_user(array("ID" => $user_id, "role" => $role));
     2569                $roles = new WP_Roles();
     2570                if ($roles->is_role($role)) { // Updates role only if role exists
     2571                    wp_update_user(array('ID' => $user_id, 'role' => $role));
     2572                } else {
     2573                    $this->_log(ADI_LOG_WARN, 'Role "' . $role . '" currently does not exist in WordPress. Role of "' . $username . '" is not set.');
     2574                }
    25462575            }
    25472576           
     
    26582687            if ( $role != '' )
    26592688            {
    2660                 wp_update_user(array('ID' => $user_id, 'role' => $role));
     2689                $roles = new WP_Roles();
     2690                if ($roles->is_role($role)) { // Updates role only if role exists
     2691                    wp_update_user(array('ID' => $user_id, 'role' => $role));
     2692                } else {
     2693                    $this->_log(ADI_LOG_WARN, 'Role "' . $role . '" currently does not exist in WordPress. Role of "' . $username . '" is not set.');
     2694                }
    26612695            }
    26622696           
  • active-directory-integration/trunk/readme.txt

    r501703 r511077  
    33Tags: authentication, active directory, ldap, authorization, security, windows
    44Requires at least: 3.0
    5 Tested up to: 3.3
     5Tested up to: 3.3.1
    66Stable tag: 1.1.3
    77
     
    5353
    5454= Known Issues =
    55 There are some issues with MultiSite. This is tracked [here](http://bt.ecw.de/view.php?id=4) and [here](http://bt.ecw.de/view.php?id=11).
     55There are some issues with MultiSite. This is tracked [here](http://bt.steindorff.de/view.php?id=4) and [here](http://bt.steindorff.de/view.php?id=11).
    5656
    5757
     
    7373
    7474= Is there an official bug tracker for ADI? =
    75 Yes. You'll find the bug tracker at http://bt.ecw.de/. You can report issues anonymously but it is recommended to create an account. This is also the right place for feature requests.
     75Yes. You'll find the bug tracker at http://bt.steindorff.de/. You can report issues anonymously but it is recommended to create an account. This is also the right place for feature requests.
    7676
    7777= I'm missing some functionality. Where can I submit a feature request? =
    78 Use the [bug tracker](http://bt.ecw.de/) (see above) at http://bt.ecw.de/.
     78Use the [bug tracker](http://bt.steindorff.de/) (see above) at http://bt.steindorff.de/.
    7979
    8080= Authentication is successfull but the user is not authorized by group membership. What is wrong? =
     
    102102* Follow the development on [Twitter](http://twitter.com/#!/adintegration).
    103103* Go to http://blog.ecw.de
    104 * See the bug tracker on http://bt.ecw.de
     104* See the bug tracker on http://bt.steindorff.de
    105105
    106106== Screenshots ==
     
    127127
    128128== Changelog ==
     129
     130= 1.1.4 =
     131* CHANGE: Only set role of user if the role already exists in WordPress. (Issue #0051)
     132* CHANGE: Now using POST instead of GET in Test Tool, so user and password are not shown in server log files (Change Request by Aren Cambre. Issue #0054.)
     133* CHANGE: The roles in Role Equivalent Groups are now always stored in lower case. (Issue #0055)
    129134
    130135= 1.1.3 =
Note: See TracChangeset for help on using the changeset viewer.