Foros del Web » Creando para Internet » Sistemas de gestión de contenidos »

Dudas con autentificador de Cluster

Estas en el tema de Dudas con autentificador de Cluster en el foro de Sistemas de gestión de contenidos en Foros del Web. Con esta directiva: session.auto_start = 0 Los scritps que usen sesiones (caso de Autentificator) deben de usar: <? session_start(); para iniciar el uso de sesiones ...

  #31 (permalink)  
Antiguo 11/11/2003, 09:02
O_O
 
Fecha de Ingreso: enero-2002
Ubicación: Santiago - Chile
Mensajes: 34.417
Antigüedad: 22 años, 8 meses
Puntos: 129
Con esta directiva:
session.auto_start = 0

Los scritps que usen sesiones (caso de Autentificator) deben de usar:

<?
session_start();

para iniciar el uso de sesiones .. si tu lo usas a "1" .. tus scripts NO deben de hacer otro session_start() .. pues esa directiva lo hace automáticamente a cada llamada de una pàgina .php ..

Podrias poner la configuración (php.ini) que tienes de sesiones .. es probable que algo no tengas configurado correctamente (usas linux? .. indica el S.O. también para tema de rutas y tal ..)

Un saludo,
__________________
Por motivos personales ya no puedo estar con Uds. Fue grato haber compartido todos estos años. Igualmente los seguiré leyendo.
  #32 (permalink)  
Antiguo 11/11/2003, 10:21
Avatar de Alfon
Colaborador
 
Fecha de Ingreso: octubre-2000
Mensajes: 1.976
Antigüedad: 23 años, 11 meses
Puntos: 14
Hola Cluster,

Gracias por contestar. Uso en este caso un W2K.

Mi config de sesiones de php.ini:

Código:
[Session]
; Handler used to store/retrieve data.
session.save_handler = files
session.save_handler = user

; Argument passed to save_handler.  In the case of files, this is the path
; where data files are stored. Note: Windows users have to change this 
; variable in order to use PHP's session functions.
; As of PHP 4.0.1, you can define the path as:
     session.save_path = c:\Apache\php\sesiones
; where N is an integer.  Instead of storing all the session files in 
; /path, what this will do is use subdirectories N-levels deep, and 
; store the session data in those directories.  This is useful if you 
; or your OS have problems with lots of files in one directory, and is 
; a more efficient layout for servers that handle lots of sessions.
; NOTE 1: PHP will not create this directory structure automatically.
;         You can use the script in the ext/session dir for that purpose.
; NOTE 2: See the section on garbage collection below if you choose to
;         use subdirectories for session storage
;session.save_path = /tmp

; Whether to use cookies.
session.use_cookies = 1

; This option enables administrators to make their users invulnerable to
; attacks which involve passing session ids in URLs; defaults to 0.
; session.use_only_cookies = 1

; Name of the session (used as cookie name).
session.name = PHPSESSID

; Initialize session on request startup.
session.auto_start = 0

; Lifetime in seconds of cookie or, if 0, until browser is restarted.
session.cookie_lifetime = 0

; The path for which the cookie is valid.
session.cookie_path = /

; The domain for which the cookie is valid.
session.cookie_domain =

; Handler used to serialize data.  php is the standard serializer of PHP.
session.serialize_handler = php

; Define the probability that the 'garbage collection' process is started
; on every session initialization.
; The probability is calculated by using gc_probability/gc_dividend,
; e.g. 1/100 means 1%.

session.gc_probability = 1
session.gc_dividend    = 100

; After this number of seconds, stored data will be seen as 'garbage' and
; cleaned up by the garbage collection process.
; WARNING: Your filesystem must store access times.  Windows FAT does
;          not.  So, see session_set_save_handler() and write your own
;          session handler with a different mechanism for cleaning up sessions.
session.gc_maxlifetime = 1440

; NOTE: If you are using the subdirectory option for storing session files
;       (see session.save_path above), then garbage collection does *not*
;       happen automatically.  You will need to do your own garbage 
;       collection through a shell script, cron entry, or some other method. 
;       For example, the following script would is the equivalent of
;       setting session.gc_maxlifetime to 1440 (1440 seconds = 24 minutes):
;          cd /path/to/sessions; find -cmin +24 | xargs rm

; PHP 4.2 and less have an undocumented feature/bug that allows you to
; to initialize a session variable in the global scope, albeit register_globals
; is disabled.  PHP 4.3 and later will warn you, if this feature is used.
; You can disable the feature and the warning seperately. At this time,
; the warning is only displayed, if bug_compat_42 is enabled.

session.bug_compat_42 = 1
session.bug_compat_warn = 1

; Check HTTP Referer to invalidate externally stored URLs containing ids.
; HTTP_REFERER has to contain this substring for the session to be
; considered as valid.
session.referer_check =

; How many bytes to read from the file.
session.entropy_length = 0

; Specified here to create the session id.
session.entropy_file =

;session.entropy_length = 16

;session.entropy_file = /dev/urandom

; Set to {nocache,private,public,} to determine HTTP caching aspects
; or leave this empty to avoid sending anti-caching headers.
session.cache_limiter = nocache

; Document expires after n minutes.
session.cache_expire = 180

; trans sid support is disabled by default.
; Use of trans sid may risk your users security. 
; Use this option with caution.
; - User may send URL contains active session ID
;   to other person via. email/irc/etc.
; - URL that contains active session ID may be stored
;   in publically accessible computer.
; - User may access your site with the same session ID
;   always using URL stored in browser's history or bookmarks.
session.use_trans_sid = 1

; The URL rewriter will look for URLs in a defined set of HTML tags.
; form/fieldset are special; if you include them here, the rewriter will
; add a hidden <input> field with the info which is otherwise appended
; to URLs.  If you want XHTML conformity, remove the form entry.
; Note that all valid entries require a "=", even if no value follows.
url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=,fieldset="
__________________
Un saludo,

Alfon
http://seguridadyredes.nireblog.com
  #33 (permalink)  
Antiguo 11/11/2003, 10:29
Ex Colaborador
 
Fecha de Ingreso: junio-2002
Mensajes: 9.091
Antigüedad: 22 años, 3 meses
Puntos: 16
Hola,

No soy ningun experto en sesiones, pero ¿es normal tener dos session.save_handler? Del manual no saco nada (http://www.php.net/manual/en/ref.ses...n.save-handler). Pero prueba a comentar el de user.

Dejame probar ...probando en local...... Exacto, con 2 lineas de session_save_handler da ese error. Deja solo el de files, a no ser que uses uno personalizado.

Pero a mi me funciona con el de files (por defecto). Comenta el otro o eliminalo.

Saludos.
__________________
Josemi

Aprendiz de mucho, maestro de poco.
  #34 (permalink)  
Antiguo 11/11/2003, 11:29
Avatar de Alfon
Colaborador
 
Fecha de Ingreso: octubre-2000
Mensajes: 1.976
Antigüedad: 23 años, 11 meses
Puntos: 14
Gracias josemi. Esto está ahora funcionando. Seguimos pues avanzando en este mundo phpero.
__________________
Un saludo,

Alfon
http://seguridadyredes.nireblog.com
  #35 (permalink)  
Antiguo 11/11/2003, 14:49
O_O
 
Fecha de Ingreso: enero-2002
Ubicación: Santiago - Chile
Mensajes: 34.417
Antigüedad: 22 años, 8 meses
Puntos: 129
jeje ..llegue tarde .. pero bueno aquí vi algún afinamiento que puedes hacer:

;session.save_path = /tmp

Preferiblemente usa alguna ruta que exista y sea válida .. Así guardaras tus sesiones en un directorio predefinido y no en el de "sistema" como lo estará haciendo (tal vez c:\windows\system en tu W2000 ...)

session.save_path = c:\php\sesiones

(create un directorio exclusivo para las sesiones y habilitas esa línea descomentandola del ; ..)

Un saludo,
__________________
Por motivos personales ya no puedo estar con Uds. Fue grato haber compartido todos estos años. Igualmente los seguiré leyendo.
  #36 (permalink)  
Antiguo 12/11/2003, 02:24
Avatar de Alfon
Colaborador
 
Fecha de Ingreso: octubre-2000
Mensajes: 1.976
Antigüedad: 23 años, 11 meses
Puntos: 14
Gracias Cluster. Llegaste tarde pero bueno.. tu eres la padre de la criatura y la verdad que el autentificador de usuarios está realmente muy bien. Lo voy a implementar en un Weblog que estoy programando.
__________________
Un saludo,

Alfon
http://seguridadyredes.nireblog.com
  #37 (permalink)  
Antiguo 19/11/2003, 19:50
 
Fecha de Ingreso: julio-2002
Ubicación: Rancagua - Chile
Mensajes: 494
Antigüedad: 22 años, 2 meses
Puntos: 0
Otra vez

Hola nuevamente:
Resulta que reinstale mi sistema operativo (format c:) y reinstale todo nuevamente, no tengo problemas con apache, ni con las BD, pero nuevamente no puedo ejecutar bien el autentificador de Cluster.
He cambiado todo, deje Register_globals en ON y cambie todas las directivas anteriores, aca esta mi configuracion

http://blackness.no-ip.com/info.php

Ojala le echen una miradita y me digan que es lo que tengo mal

Gracias y Salu2
__________________
AK.T.I.V.E.tm Live, Never DIE
  #38 (permalink)  
Antiguo 20/11/2003, 07:21
O_O
 
Fecha de Ingreso: enero-2002
Ubicación: Santiago - Chile
Mensajes: 34.417
Antigüedad: 22 años, 8 meses
Puntos: 129
Ya te comenté el problema puntual con el error "cod.1" que viene de HTTP_REFERER ..

Sigues usando algún Firewall, Router (de tu conexión ADSL) o similar? .. Que S.O. Usas? .. Revisa esos puntos o bien elimina esa porción del código que se ha comentado ..

O .. que problema tienes ahora?.

Un saludo,
__________________
Por motivos personales ya no puedo estar con Uds. Fue grato haber compartido todos estos años. Igualmente los seguiré leyendo.
  #39 (permalink)  
Antiguo 20/11/2003, 08:17
 
Fecha de Ingreso: julio-2002
Ubicación: Rancagua - Chile
Mensajes: 494
Antigüedad: 22 años, 2 meses
Puntos: 0
Tengo Windows 2000 Profesional, tengo instalado un Firewall pero para las pruebas lo deshabilito.
Vamos a ver que puede ser.
Salu2 y Gracias
__________________
AK.T.I.V.E.tm Live, Never DIE
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta

SíEste tema le ha gustado a 1 personas




La zona horaria es GMT -6. Ahora son las 21:28.