Subversion Repositories wimsdev

Rev

Rev 2732 | Rev 3666 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
2732 guerimand 1
!if $job=lightpopup
2
 !changeto jobs/lightpopup.proc
3
!endif
3261 obado 4
 
23 reyssat 5
wims_prefix=class user tmp n sharing sharable ident
6
!if $job=help
7
 wims_module_log=help
8
 !exit
9
!endif
3261 obado 10
 
391 obado 11
!read defs
23 reyssat 12
 
13
job=!lower $job
3261 obado 14
!bound job within $allowed_actions_jobs,$allowed_file_jobs,$allowed_jobs_without_auth default $
23 reyssat 15
option=!items2words $option
16
option=!words2items $option
17
code=!word 1 of $code
18
 
19
 
3261 obado 20
!if $job notin $allowed_jobs_without_auth or $ident != $empty
21
	# le script autchars permet de definir les listes de caracteres alphanumeriques et de ponctuation
22
	# il definit egalement la fourchette de longueur autorise des login/mdp
23
	!read adm/class/authchars
24
	# Le script var.check verifie l'authentification de l'utilisateur
25
	!read var.check	
26
!endif
27
 
23 reyssat 28
!if $error=$empty
29
 !read jobs/$job.proc
30
!endif
31
 
391 obado 32
#Lorsque l'on sort de la procedure "job", il ne doit tjs pas y avoir d'erreur.
23 reyssat 33
!if $error!=$empty
34
 !changeto error.proc $error
35
!endif
36
 
37
!if $code=$empty
3261 obado 38
  !if $ident_type != xmlformat
39
	ok=OK
40
  !else
41
  	ok=<?xml version="1.0" encoding="$encoding"?>\
42
<!DOCTYPE methodResponse PUBLIC "XML9-RPC" "http://ticewims.unice.fr/xml-rpc/xml-rpc.dtd">\
43
<methodResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ticewims.unice.fr/xml-rpc/xml-rpc.xsd">\
44
<params><param><value><string>OK</string></value></param>
45
  !endif
23 reyssat 46
!else
3261 obado 47
  !if $ident_type != xmlformat
48
	ok=OK $code$ident_type
49
  !else
50
  	ok=<?xml version="1.0" encoding="$encoding"?>\
51
<!DOCTYPE methodResponse PUBLIC "XML9-RPC" "http://ticewims.unice.fr/xml-rpc/xml-rpc.dtd">\
52
<methodResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://ticewims.unice.fr/xml-rpc/xml-rpc.xsd">\
53
	<params><param><value><struct><member>\
54
		<name>code</name>\
55
		<value><string>$code</string></value>\
56
	</member>\
57
 
58
  !endif
23 reyssat 59
!endif
60
 
3261 obado 61
!if $ident_type != xmlformat
62
	!shortout $header\
23 reyssat 63
 
3261 obado 64
!else
65
	!shortout $header_xml\
391 obado 66
 
3261 obado 67
!endif
68
 
69
 
70
 
391 obado 71
!if $job isitemof $allowed_actions_jobs
72
 !shortout $ok\
73
 
23 reyssat 74
 !read types/$ident_type
75
!endif
76
 
391 obado 77
!if $job isitemof $allowed_file_jobs
23 reyssat 78
 !sh cat $wims_home/$fname
79
!endif
80
 
81
!if $job notwordof authuser
82
 wims_mode=popup
83
!endif
84
 
3261 obado 85
wims_module_log=$job $ident -> $qclass $quser