You have to create a forward for each users mailbox: called spam.fwd
Save this as V B S
 
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
'       Written By Patrick Moss For Cyberlink, Inc.      '
'      Creates a Forward for all users of all Domains       '
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Dim fso, strFile,FileToCheck,rootdirectory, rc
 
Const ForReading = 1, ForWriting = 2, ForAppending = 8 
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
'CHANGE THESE PATH's TO SUIT YOUR NEEDS
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
strFile = "d:\imail\mailfilter_scripts\spam.fwd"                     'CREATE A GENERIC FWD to COPY TO ALL USERS - SET directory here
FileToCheck = "\spam.fwd" 
RootDirectory = "d:\imail\domains"
 
 
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
folderlist(RootDirectory)
Set WshShell = WScript.CreateObject("WScript.Shell")
Wscript.Echo "All Done"
Set WshShell = nothing
 
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
function fileexist(filespec)
On Error Resume Next
dim msg, fso
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
if (fso.FileExists(filespec)) Then
 msg = 1
else
 msg = 0
end if
fileexist = msg
set fso = Nothing
end Function
 
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub folderlist(folderspec) 
On Error Resume Next
dim f,f1,sf, fso
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
set f = fso.GetFolder(folderspec) 
set sf = f.SubFolders
For Each f1 in sf
 findusersfldr(f1) 
Next 
Set F = NOTHING
Set sf = NOTHING
set fso = NOTHING
end Sub
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub findusersfldr(folderspec)
Dim f3,f2,sf1,fso
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
set f2 = fso.GetFolder(folderspec) 
set sf1 = f2.SubFolders
For Each f3 in sf1
 If LCase(f3.name) ="users" Then
    filemanip(f3.path)
 End If
Next
Set F3 = NOTHING
set sf1 = NOTHING
set fso = nothing
End Sub
''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub filemanip(fldr)
Dim filelocate,f4,f5,sf2,fso
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
set f4 = fso.GetFolder(fldr) 
set sf2 = f4.SubFolders
For Each f5 in sf2
  If fileexist(f5.path & filetocheck) = 0 Then
  CreateFile(f5.path & filetocheck)
  Else
   
  End If
Next
set f4 = NOTHING
Set sf2 = Nothing
Set fso = Nothing
end Sub
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Sub CreateFile(file)
Dim TextFile,fso
On Error Resume Next
Set fso = Wscript.CreateObject("Scripting.FileSystemObject")
Set TextFile = fso.GetFile(strFile) 
textFile.Copy file
Set textfile = Nothing
Set FSO = Nothing
End Sub

'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Patrick Moss - Technical Support Group - Assistant Systems Administrator
CyberLink, Inc.� - Featuring SurfPure Filtered Internet Access
http://support.cyberlink.com
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]>
(888)Plug-in2
(219)235-1400
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Calvin Mitchell
Sent: Monday, July 10, 2000 11:38 AM
To: [EMAIL PROTECTED]
Subject: [IMail Forum] Spam Mail

We have a problem with people spamming are mail servers. Now we have setup up rules and them put send to mail box Spam.
But all it does is create a folder in there webmail dir called SPAM and all there mail goes there. We want all the mail to go to one account like [EMAIL PROTECTED] and not to the peoples webmail.
 
 
Calvin Mitchell
Montereybay.com
Tel (831)648-8111
Fax (831)648-8113

Reply via email to