Issues (661)

Security Analysis    not enabled

This project does not seem to handle request data directly as such no vulnerable execution paths were found.

  Cross-Site Scripting
Cross-Site Scripting enables an attacker to inject code into the response of a web-request that is viewed by other users. It can for example be used to bypass access controls, or even to take over other users' accounts.
  File Exposure
File Exposure allows an attacker to gain access to local files that he should not be able to access. These files can for example include database credentials, or other configuration files.
  File Manipulation
File Manipulation enables an attacker to write custom data to files. This potentially leads to injection of arbitrary code on the server.
  Object Injection
Object Injection enables an attacker to inject an object into PHP code, and can lead to arbitrary code execution, file exposure, or file manipulation attacks.
  Code Injection
Code Injection enables an attacker to execute arbitrary code on the server.
  Response Splitting
Response Splitting can be used to send arbitrary responses.
  File Inclusion
File Inclusion enables an attacker to inject custom files into PHP's file loading mechanism, either explicitly passed to include, or for example via PHP's auto-loading mechanism.
  Command Injection
Command Injection enables an attacker to inject a shell command that is execute with the privileges of the web-server. This can be used to expose sensitive data, or gain access of your server.
  SQL Injection
SQL Injection enables an attacker to execute arbitrary SQL code on your database server gaining access to user data, or manipulating user data.
  XPath Injection
XPath Injection enables an attacker to modify the parts of XML document that are read. If that XML document is for example used for authentication, this can lead to further vulnerabilities similar to SQL Injection.
  LDAP Injection
LDAP Injection enables an attacker to inject LDAP statements potentially granting permission to run unauthorized queries, or modify content inside the LDAP tree.
  Header Injection
  Other Vulnerability
This category comprises other attack vectors such as manipulating the PHP runtime, loading custom extensions, freezing the runtime, or similar.
  Regex Injection
Regex Injection enables an attacker to execute arbitrary code in your PHP process.
  XML Injection
XML Injection enables an attacker to read files on your local filesystem including configuration files, or can be abused to freeze your web-server process.
  Variable Injection
Variable Injection enables an attacker to overwrite program variables with custom data, and can lead to further vulnerabilities.
Unfortunately, the security analysis is currently not available for your project. If you are a non-commercial open-source project, please contact support to gain access.

include/oninstall.inc.php (1 issue)

Severity

Upgrade to new PHP Analysis Engine

These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more

1
<?php
2
/**
3
 * Mylinks install functions.php
4
 *
5
 * LICENSE
6
 *
7
 * You may not change or alter any portion of this comment or credits
8
 * of supporting developers from this source code or any supporting source code
9
 * which is considered copyrighted (c) material of the original comment or credit authors.
10
 *
11
 * @copyright:: {@link http://xoops.org/ XOOPS Project}
12
 * @license  ::    {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License}
13
 * @package  ::   mylinks
14
 * @author   ::    zyspec ([email protected])
15
 */
16
17
$moduleDirName = basename(dirname(__DIR__));
18
19
/**
20
 * @param $xoopsModule
21
 * @return bool
22
 */
23
function xoops_module_pre_install_mylinks_base(&$xoopsModule)
24
{
25
    global $xoopsDB;
26
    $retVal = true;
27
28
    $minPHPVersion   = $xoopsModule->getInfo('min_php');
29
    $minSQLVersion   = $xoopsModule->getInfo('min_sql');
30
    $minXoopsVersion = $xoopsModule->getInfo('min_xoops');
31
32
    /*
33
     * Error Messages
34
     */
35
    $phpErrMsg   = "<span style='color: red; font-weight: bold;'>YOUR PHP VERSION MUST BE UPGRADED TO AT LEAST VERSION {$minPHPVersion} TO USE THIS MODULE</span>";
36
    $mysqlErrMsg = "<span style='color: red; font-weight: bold;'>YOUR MYSQL DATABASE VERSION MUST BE UPGRADED TO AT LEAST VERSION {$minSQLVersion} TO USE THIS MODULE</span>";
37
    $xoopsErrMsg = "<span style='color: red; font-weight: bold;'>YOUR XOOPS VERSION MUST BE UPGRADED TO AT LEAST VERSION {$minXoopsVersion} TO USE THIS MODULE</span>";
38
39
    // Check if PHP version is supported
40
    if (version_compare(PHP_VERSION, $minPHPVersion) < 0) {
41
        $retVal = false;
42
        $xoopsModule->setErrors($phpErrMsg);
43
    } else {
44
        // Check if MySQL version is supported
45
        $minSQLSupported = explode('.', $minSQLVersion);
46
        $sql             = $xoopsDB->query('SELECT version() AS sqlver');
47
        $result          = $xoopsDB->fetchObject($sql);
48
        $currSQLVer      = $result->sqlver;
49
        $sqlVerArray     = explode('.', $currSQLVer);
50
        $sqlVerArray     = array_map('intval', $sqlVerArray); //strip off non-integer revision chars
51
52
        if ($sqlVerArray[0] < $minSQLSupported[0]) {
53
            $retVal = false;
54
            $xoopsModule->setErrors($mysqlErrMsg);
55
        } elseif ($sqlVerArray[0] == $minSQLSupported[0]) {
56
            if ($sqlVerArray[1] < $minSQLSupported[1]) {
57
                $retVal = false;
58
                $xoopsModule->setErrors($mysqlErrMsg);
59
            } elseif (($sqlVerArray[1] == $minSQLSupported[1]) && ($sqlVerArray[2] < $minSQLSupported[2])) {
60
                $retVal = false;
61
                $xoopsModule->setErrors($mysqlErrMsg);
62
            }
63
        }
64
65
        if ($retVal) {
66
            // Check if this XOOPS version is supported
67
            $curXoopsVersion     = substr(XOOPS_VERSION, 6);
68
            if (version_compare($curXoopsVersion, $minXoopsVersion, '<')) {
69
                $retVal = false;
70
                $xoopsModule->setErrors(sprintf($xoopsErrMsg, $minXoopsVersion, $curXoopsVersion));
71
            }
72
        }
73
    }
74
75
    return $retVal;
76
}
77
78
/**
79
 * @param $xoopsModule
80
 * @return bool
81
 */
82
function xoops_module_install_mylinks_base(&$xoopsModule)
0 ignored issues
show
The parameter $xoopsModule is not used and could be removed.

This check looks from parameters that have been defined for a function or method, but which are not used in the method body.

Loading history...
83
{
84
    return true;
85
}
86
87
/**
88
 * eval functions to support module relocation (directory renaming)
89
 */
90
eval('function xoops_module_install_' . $moduleDirName . '(&$module=NULL)
91
        {
92
        return xoops_module_install_mylinks_base($module);
93
        }
94
    ');
95
eval('function xoops_module_pre_install_' . $moduleDirName . '(&$module=NULL)
96
        {
97
        return xoops_module_pre_install_mylinks_base($module);
98
        }
99
    ');
100