Ad Widget

Collapse

SAML (Single Sign On) Issue

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pyritejoe
    Junior Member
    • Aug 2022
    • 15

    #1

    SAML (Single Sign On) Issue

    I am setting up saml auth and it seems to be mostly working, but I get the below error when trying to do a login:

    Value "cn=name,ou=name,ou=name,ou=name,ou=name,ou=na me,o u=name,o=name ,c=name" is too long for field "name" - 120 characters. Allowed length is 64 characters.

    The users are creatyed seeing that I have JIT enabled, but it wont login. Any help will be appreciated.
  • pyritejoe
    Junior Member
    • Aug 2022
    • 15

    #2
    A co-worker of mine figured it out.

    I was able to find in the Zabbix documentation that the /include/schema.inc.php file is used to set all of the tables used for the Zabbix database, including character size limits. Within that document is the scim_group table used for user provisioning:


    'scim_group' => [
    'key' => 'scim_groupid',
    'fields' => [
    'scim_groupid' => [
    'null' => false,
    'type' => DB::FIELD_TYPE_ID,
    'length' => 20
    ],
    'name' => [
    'null' => false,
    'type' => DB::FIELD_TYPE_CHAR,
    'length' => 64, <----- Needs to be 128
    'default' => ''
    ]
    Upon changing that, I logged into Zabbix and got the eror: System error occurred:
    SQL statement execution has failed "INSERT INTO scim_group

    Which meant that I had to go fix that table in in MYSQL to increase the character length there as well:

    mysql -u zabbix -p

    USE zabbix;

    mysql> SHOW COLUMNS FROM scim_group;
    +--------------+-----------------+------+-----+---------+-------+
    | Field | Type | Null | Key | Default | Extra |
    +--------------+-----------------+------+-----+---------+-------+
    | scim_groupid | bigint unsigned | NO | PRI | NULL | |
    | name | varchar(64) | NO | UNI | | |
    +--------------+-----------------+------+-----+---------+-------+
    2 rows in set (0.01 sec)
    mysql> ALTER TABLE scim_group MODIFY COLUMN name VARCHAR(128);
    Query OK, 0 rows affected (0.10 sec)
    Records: 0 Duplicates: 0 Warnings: 0

    mysql> SHOW COLUMNS FROM scim_group;
    +--------------+-----------------+------+-----+---------+-------+
    | Field | Type | Null | Key | Default | Extra |
    +--------------+-----------------+------+-----+---------+-------+
    | scim_groupid | bigint unsigned | NO | PRI | NULL | |
    | name | varchar(128) | YES | UNI | NULL | |
    +--------------+-----------------+------+-----+---------+-------+
    2 rows in set (0.01 sec)

    Comment

    Working...