1
|
<%
|
2
|
' FCKeditor - The text editor for Internet - http://www.fckeditor.net
|
3
|
' Copyright (C) 2003-2009 Frederico Caldeira Knabben
|
4
|
'
|
5
|
' == BEGIN LICENSE ==
|
6
|
'
|
7
|
' Licensed under the terms of any of the following licenses at your
|
8
|
' choice:
|
9
|
'
|
10
|
' - GNU General Public License Version 2 or later (the "GPL")
|
11
|
' http://www.gnu.org/licenses/gpl.html
|
12
|
'
|
13
|
' - GNU Lesser General Public License Version 2.1 or later (the "LGPL")
|
14
|
' http://www.gnu.org/licenses/lgpl.html
|
15
|
'
|
16
|
' - Mozilla Public License Version 1.1 or later (the "MPL")
|
17
|
' http://www.mozilla.org/MPL/MPL-1.1.html
|
18
|
'
|
19
|
' == END LICENSE ==
|
20
|
'
|
21
|
' Configuration file for the File Manager Connector for ASP.
|
22
|
%>
|
23
|
<%
|
24
|
|
25
|
' SECURITY: You must explicitly enable this "connector" (set it to "True").
|
26
|
' WARNING: don't just set "ConfigIsEnabled = true", you must be sure that only
|
27
|
' authenticated users can access this file or use some kind of session checking.
|
28
|
Dim ConfigIsEnabled
|
29
|
ConfigIsEnabled = False
|
30
|
|
31
|
' Path to user files relative to the document root.
|
32
|
' This setting is preserved only for backward compatibility.
|
33
|
' You should look at the settings for each resource type to get the full potential
|
34
|
Dim ConfigUserFilesPath
|
35
|
ConfigUserFilesPath = "/userfiles/"
|
36
|
|
37
|
' Due to security issues with Apache modules, it is recommended to leave the
|
38
|
' following setting enabled.
|
39
|
Dim ConfigForceSingleExtension
|
40
|
ConfigForceSingleExtension = true
|
41
|
|
42
|
' What the user can do with this connector
|
43
|
Dim ConfigAllowedCommands
|
44
|
ConfigAllowedCommands = "QuickUpload|FileUpload|GetFolders|GetFoldersAndFiles|CreateFolder"
|
45
|
|
46
|
' Allowed Resource Types
|
47
|
Dim ConfigAllowedTypes
|
48
|
ConfigAllowedTypes = "File|Image|Flash|Media"
|
49
|
|
50
|
' For security, HTML is allowed in the first Kb of data for files having the
|
51
|
' following extensions only.
|
52
|
Dim ConfigHtmlExtensions
|
53
|
ConfigHtmlExtensions = "html|htm|xml|xsd|txt|js"
|
54
|
'
|
55
|
' Configuration settings for each Resource Type
|
56
|
'
|
57
|
' - AllowedExtensions: the possible extensions that can be allowed.
|
58
|
' If it is empty then any file type can be uploaded.
|
59
|
'
|
60
|
' - DeniedExtensions: The extensions that won't be allowed.
|
61
|
' If it is empty then no restrictions are done here.
|
62
|
'
|
63
|
' For a file to be uploaded it has to fulfill both the AllowedExtensions
|
64
|
' and DeniedExtensions (that's it: not being denied) conditions.
|
65
|
'
|
66
|
' - FileTypesPath: the virtual folder relative to the document root where
|
67
|
' these resources will be located.
|
68
|
' Attention: It must start and end with a slash: '/'
|
69
|
'
|
70
|
' - FileTypesAbsolutePath: the physical path to the above folder. It must be
|
71
|
' an absolute path.
|
72
|
' If it's an empty string then it will be autocalculated.
|
73
|
' Useful if you are using a virtual directory, symbolic link or alias.
|
74
|
' Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'.
|
75
|
' Attention: The above 'FileTypesPath' must point to the same directory.
|
76
|
' Attention: It must end with a slash: '/'
|
77
|
'
|
78
|
' - QuickUploadPath: the virtual folder relative to the document root where
|
79
|
' these resources will be uploaded using the Upload tab in the resources
|
80
|
' dialogs.
|
81
|
' Attention: It must start and end with a slash: '/'
|
82
|
'
|
83
|
' - QuickUploadAbsolutePath: the physical path to the above folder. It must be
|
84
|
' an absolute path.
|
85
|
' If it's an empty string then it will be autocalculated.
|
86
|
' Useful if you are using a virtual directory, symbolic link or alias.
|
87
|
' Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'.
|
88
|
' Attention: The above 'QuickUploadPath' must point to the same directory.
|
89
|
' Attention: It must end with a slash: '/'
|
90
|
'
|
91
|
|
92
|
Dim ConfigAllowedExtensions, ConfigDeniedExtensions, ConfigFileTypesPath, ConfigFileTypesAbsolutePath, ConfigQuickUploadPath, ConfigQuickUploadAbsolutePath
|
93
|
Set ConfigAllowedExtensions = CreateObject( "Scripting.Dictionary" )
|
94
|
Set ConfigDeniedExtensions = CreateObject( "Scripting.Dictionary" )
|
95
|
Set ConfigFileTypesPath = CreateObject( "Scripting.Dictionary" )
|
96
|
Set ConfigFileTypesAbsolutePath = CreateObject( "Scripting.Dictionary" )
|
97
|
Set ConfigQuickUploadPath = CreateObject( "Scripting.Dictionary" )
|
98
|
Set ConfigQuickUploadAbsolutePath = CreateObject( "Scripting.Dictionary" )
|
99
|
|
100
|
ConfigAllowedExtensions.Add "File", "7z|aiff|asf|avi|bmp|csv|doc|fla|flv|gif|gz|gzip|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|ods|odt|pdf|png|ppt|pxd|qt|ram|rar|rm|rmi|rmvb|rtf|sdc|sitd|swf|sxc|sxw|tar|tgz|tif|tiff|txt|vsd|wav|wma|wmv|xls|xml|zip"
|
101
|
ConfigDeniedExtensions.Add "File", ""
|
102
|
ConfigFileTypesPath.Add "File", ConfigUserFilesPath & "file/"
|
103
|
ConfigFileTypesAbsolutePath.Add "File", ""
|
104
|
ConfigQuickUploadPath.Add "File", ConfigUserFilesPath
|
105
|
ConfigQuickUploadAbsolutePath.Add "File", ""
|
106
|
|
107
|
ConfigAllowedExtensions.Add "Image", "bmp|gif|jpeg|jpg|png"
|
108
|
ConfigDeniedExtensions.Add "Image", ""
|
109
|
ConfigFileTypesPath.Add "Image", ConfigUserFilesPath & "image/"
|
110
|
ConfigFileTypesAbsolutePath.Add "Image", ""
|
111
|
ConfigQuickUploadPath.Add "Image", ConfigUserFilesPath
|
112
|
ConfigQuickUploadAbsolutePath.Add "Image", ""
|
113
|
|
114
|
ConfigAllowedExtensions.Add "Flash", "swf|flv"
|
115
|
ConfigDeniedExtensions.Add "Flash", ""
|
116
|
ConfigFileTypesPath.Add "Flash", ConfigUserFilesPath & "flash/"
|
117
|
ConfigFileTypesAbsolutePath.Add "Flash", ""
|
118
|
ConfigQuickUploadPath.Add "Flash", ConfigUserFilesPath
|
119
|
ConfigQuickUploadAbsolutePath.Add "Flash", ""
|
120
|
|
121
|
ConfigAllowedExtensions.Add "Media", "aiff|asf|avi|bmp|fla|flv|gif|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|png|qt|ram|rm|rmi|rmvb|swf|tif|tiff|wav|wma|wmv"
|
122
|
ConfigDeniedExtensions.Add "Media", ""
|
123
|
ConfigFileTypesPath.Add "Media", ConfigUserFilesPath & "media/"
|
124
|
ConfigFileTypesAbsolutePath.Add "Media", ""
|
125
|
ConfigQuickUploadPath.Add "Media", ConfigUserFilesPath
|
126
|
ConfigQuickUploadAbsolutePath.Add "Media", ""
|
127
|
|
128
|
%>
|