Override kernel datatypes and CAS authentication

Author Message

B Pierre

Friday 11 February 2011 3:27:19 am

Hi

I try to override kernel datatypes to make a CAS authentication but it's doesn't work. First I have create an extension with this arborescence :

ezCAS -> settings -> content.ini.append.php
-> kernel -> classes -> datatypes -> ezuser -> ezuser.php

My file "content.ini.append.php" contains this lines :

"

[DataTypeSettings]
RepositoryDirectories []
RepositoryDirectories []=extension/ezCAS/kernel/classes/datatypes

"

Next I have modify the "config.php-RECOMMENDED" as this :

"

/*
KERNEL OVERRIDES
----------------
This setting controls if eZ Publish's autoload system should allow, and
load classes, which override kernel classes from extensions.
*/
define( 'EZP_AUTOLOAD_ALLOW_KERNEL_OVERRIDE', true );

"

(I have uncomment and replace "false" with "true")

To finish I have execute this commands :
php bin/php/ezpgenerateautoloads.php -o
php bin/php/ezpgenerateautoloads.php

But I have this error message :

"

Warning:
Class eZUser in file extension/ezCAS/kernel/classes/datatypes/ezuzerCAS/ezuser.php is already defined in:
kernel/classes/datatypes/ezuser/ezuser.php (autoload/ezp_kernel.php)
This class was not added to the autoload array.

"

What's wrong ?

I have used this topic http://share.ez.no/forums/developer/override-kernel-classes

eZ Version : 4.3

Thanks for your help.

Gaetano Giunta

Friday 11 February 2011 6:51:20 am

Why don't you just use a custom sso handler / logon handler instead? Also there are at least 2 working cas extensions on projects.ez.no...

Principal Consultant International Business
Member of the Community Project Board

B Pierre

Friday 11 February 2011 7:18:18 am

The two cas extensions not working ^^

More exactly one modify directly the kernel classes and the second makes a php error.

I've solved my problem, its necessary rename "config.php-RECOMMENDED" in "config.php" ....

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.