Fork me on GitHub




« 1 ... 7 8 9 (10)


Re: Security Image Weblinks
Xoops accro
Inscrit: 25/02/2004 00:20
De Région parisienne
Messages: 2526
Concernant la personnalisation de l'image, il y a le fichier :
class/captcha/config.image.php

Concernant les permissions, il y a surement quelque chose à faire avec le fichier
class/captcha/config.php
Mais par défaut, le captcha de la 2.3.x est activé uniquement pour les non-membres.

Posté le : 05/01/2009 12:45
Partager Twitter Partagez cette article sur GG+
Re: Security Image Weblinks
Guest_
Ok, merci pour l'info.

Posté le : 05/01/2009 17:33
Partager Twitter Partagez cette article sur GG+
Re: Security Image Weblinks
Guest_
b'jour

Le module Tellafriend n'est plus tout à fait à jour :

• le hack de Dugris ne fait plus effet sur Xoops 2.3.3 (voir ici le code), où alors c'est moi qui ait loupé une marche ?

• et évidemment le captcha intégré à Xoops - apport plus récent que le code du module Tellafriend - n'est pas pris en compte, il ne s'affiche pas

• en outre, aucune étoile censée indiquer les champs obligatoires ne s'affiche (c'est possible de les rajouter dans les traductions... m'enfin y a sûrement mieux

... bref si un développeur a du temps à consacrer à la mise à jour de ce module, j'en profiterais volontiers de façon éhontée

Posté le : 22/10/2009 01:34
Partager Twitter Partagez cette article sur GG+
Extgallery 1.8 de Zoulou et securityimage de Dugris
Xoops accro
Inscrit: 16/08/2005 19:46
De Nanterre
Messages: 2331
Pour une autre méthode de protection, notamment pour les envoi par "send e-cards", suivez ce lien.
Sinon, avec le module Securityimage de Dugris, c'est comme cela.

ATTENTION!! N'OUBLIEZ PAS D'ENLEVER LES ESPACES DU MOT:
j a v a s c r i p t


Dans le fichier public-upload.php

$permHandler ExtgalleryPublicPermHandler::getHandler();
if(
count($permHandler->getAuthorizedPublicCat($xoopsUser'public_upload')) < 1) {
    
redirect_header("index.php"3_MD_EXTGALLERY_NOPERM);
    exit;
}
switch(
$step) {
    case 
'enreg':
// Hack SecurityImage de Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
    
redirect_header'j a v a s c r i p t:history.go(-1)'2_SECURITYIMAGE_ERROR ) ;
    exit();
    }
// Hack SecurityImage de Dugris 
        
$photoHandler xoops_getmodulehandler('publicphoto''extgallery');
        
$result $photoHandler->postPhotoTraitement('photo_file'false);
        if(
$result == 2) {

Et enfin, ceci
$plugin xoops_getmodulehandler('plugin''extgallery');
        
$plugin->triggerEvent('photoForm'$form);
        
$form->addElement(new XoopsFormHidden("step"'enreg'));
// Hack SecurityImage de Dugris
        
if (defined('SECURITYIMAGE_INCLUDED')) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if (
$security_image->render()) {
        
$form->addElement($security_imagetrue);
        }
    }
// Hack SecurityImage de Dugris
        
$form->addElement(new XoopsFormButton("""submit"_SUBMIT"submit"));
        
$form->display();
        include(
XOOPS_ROOT_PATH."/footer.php");
        break;


===================================
Pour le send e-cards, vous pouvez faire ceci:

Ouvrez le fichier public-sendecard.php

REMPLACER EXACTEMENT CECI
include_once XOOPS_ROOT_PATH.'/modules/extgallery/class/php-captcha.inc.php';
        
        
// Enable captcha only if GD is Used
        
if($xoopsModuleConfig['graphic_lib'] == 'GD') {
            if (!
PhpCaptcha::Validate($_POST['captcha'])) {
                
redirect_header("public-photo.php?photoId=".$photoId."#photoNav"3_MD_EXTGALLERY_CAPTCHA_ERROR);
                exit;
            }
        }


PAR CELA:
// Hack SecurityImage de Dugris
    
include_once(XOOPS_ROOT_PATH "/class/xoopsformloader.php");
    if ( 
defined('SECURITYIMAGE_INCLUDED') && !SecurityImage::CheckSecurityImage() ) {
    
redirect_header'j a v a s c r i p t:history.go(-1)'2_SECURITYIMAGE_ERROR ) ;
    exit();
    }
// Hack SecurityImage de Dugris


ET ENFIN, REMPLACER EXACTEMENT CECI
// Enable captcha only if GD is Used
        
if($xoopsModuleConfig['graphic_lib'] == 'GD') {
            
$form->addElement(new XoopsFormText(_MD_EXTGALLERY_SECURITY'captcha''10''5'''),false);
        }


PAR CELA:
// Hack SecurityImage de Dugris
        
if (defined('SECURITYIMAGE_INCLUDED')) {
        
$security_image = new SecurityImage_SECURITYIMAGE_GETCODE );
        if (
$security_image->render()) {
        
$form->addElement($security_imagetrue);
        }
    }
// Hack SecurityImage de Dugris


Et voila

Pour les nullos, voici les 2 fichiers zippés dans ce forum

A+++

Posté le : 10/06/2010 19:45
Partager Twitter Partagez cette article sur GG+

 Haut   Précédent   Suivant
« 1 ... 7 8 9 (10)



Vous pouvez voir les sujets.
Vous ne pouvez pas débuter de nouveaux sujets.
Vous ne pouvez pas répondre aux contributions.
Vous ne pouvez pas éditer vos contributions.
Vous ne pouvez pas effacez vos contributions.
Vous ne pouvez pas ajouter de nouveaux sondages.
Vous ne pouvez pas voter en sondage.
Vous ne pouvez pas attacher des fichiers à vos contributions.
Vous ne pouvez pas poster sans approbation.

Propulsé avec XOOPS | Graphisme adapté par Tatane, Grosdunord, Montuy337513

49 Personne(s) en ligne (36 Personne(s) connectée(s) sur Forum) | Utilisateur(s): 0 | Invité(s): 49 | Plus ...