PHP ClamAV Lib 0.12a review
DownloadPHP ClamaAV Lib is a PHP extension that allows you to incorporate virus scanning features in your PHP scripts. It uses the Clam An
|
|
PHP ClamaAV Lib is a PHP extension that allows you to incorporate virus scanning features in your PHP scripts.
It uses the Clam Antivirus API (libclamav) for virus scanning. There are supported functions for file scanning and buffer scanning.
Functions Reference:
string cl_scanfile(string filename);
Description:
Scan a file given a filename.
Parameters:
filename: the absolute / relative path to the file.
Return value:
Returns the name of the virus if this is found and returns null when no virus is found.
cl_scanfile_ex(string filename, int options, string virusname, int retcode);
Description:
Scan a file given a filename (extended version), it supports the ClamAV scanning options and returns the virusname and return code of the 'cl_scanfile()' API function.
Parameters:
filename: the absolute / relative path to the file.
options: ClamAV scanning options.
virusname: This parameter is used to retrieve the virusname if a virus was found.
retcode: This parameter is used to retrieve the return code of the cl_scanfile API function.
string cl_scanbuff();
Description:
Scan a file given a string buffer.
Parameters:
buffer: string buffer to be scanned.
Return value:
Returns the name of the virus if this is found and returns null when no virus is found.
string cl_scanbuff_ex(string buffer, int size_buffer, string virusname, int retcode);
Description:
Scan a file given a string buffer (extended version), returns the virusname and return code of the 'cl_scanfile()' API function..
Parameters:
buffer: string buffer to be scanned.
size_buffer: size of the buffer.
virusname: This parameter is used to retrieve the virusname if a virus was found.
retcode: This parameter is used to retrieve the return code of the cl_scanfile API function.
string cl_pretcode(int retcode);
Description:
Translates the ClamAV return code.
Parameters:
retcode: The return code of a cl_scanfile_ex(filename, options, virusname, retcode) or cl_scanbuff_ex(buffer, size_buffer, virusname, retcode) function.
Return value:
Returns a string with the return code description.
Compatibility functions:
string clam_scan_buffer(string buffer);
string clam_scan_file(string filename);
string clam_get_version();
PHP ClamAV Lib 0.12a keywords