GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Issues (164)

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.

src/DB/rules/insert.php (3 issues)

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
namespace PhpBoot\DB\rules\insert;
3
4
use PhpBoot\DB\DB;
5
use PhpBoot\DB\impls\OnDuplicateKeyUpdateImpl;
6
use PhpBoot\DB\rules\basic\BasicRule;
7
use PhpBoot\DB\rules\basic\ExecRule;
8
use PhpBoot\DB\impls\InsertImpl;
9
use PhpBoot\DB\impls\ValuesImpl;
10
11
require_once dirname(__DIR__).'/impls.php';
12
require_once __DIR__.'/basic.php';
13
14
class InsertRule extends BasicRule
15
{
16
    /**
17
     * 
18
     * insertInto('table')->values([1,2]) => "INSERT INTO table VALUES(1,2)"
19
     * @param string $table
20
     * @return \PhpBoot\DB\rules\insert\ValuesRule
21
     */
22 8
    public function insertInto($table) {
23 8
        InsertImpl::insertInto($this->context, $table);
24 8
        return new ValuesRule($this->context);
25
    }
26
}
27
class ValuesRule extends BasicRule
28
{
29
    /**
30
     *
31
     * insertInto('table')->values([1,2]) => "INSERT INTO table VALUES(1,2)"
32
     * insertInto('table')->values(['a'=>1, 'b'=>Sql::raw('now()')]) => "INSERT INTO table(a,b) VALUES(1,now())"
33
     * @param array $values
34
     * @return \PhpBoot\DB\rules\insert\OnDuplicateKeyUpdateRule
35
     */
36 5
    public function values(array $values) {
37 5
        ValuesImpl::values($this->context, $values);
38 5
        return new OnDuplicateKeyUpdateRule($this->context);
39
    }
40
41
    /**
42
     * insertInto('table')->batchValues([[1,2],[3,4]]) => "INSERT INTO table VALUES(1,2), (3,2)"
43
     *
44
     * @param array $values
45
     * @return \PhpBoot\DB\rules\insert\OnDuplicateKeyUpdateRule
46
     */
47 3
    public function batchValues(array $values){
48 3
        ValuesImpl::batchValues($this->context, $values);
49 3
        return new OnDuplicateKeyUpdateRule($this->context);
50
    }
51
}
52
53
class OnDuplicateKeyUpdateRule extends ExecRule
54
{
55 8
    public function __construct($context)
56
    {
57 8
        parent::__construct($context);
58 8
        $this->impl = new OnDuplicateKeyUpdateImpl();
59 8
    }
60
61
//    /**
62
//     *
63
//     * insertInto('table')
64
//     *      ->values(['a'=>1, 'b'=>Sql::raw('now()')])
65
//     *      ->onDuplicateKeyUpdate('a', Sql::raw('a+1'))
66
//     *  => "INSERT INTO table(a,b) VALUES(1,now()) ON DUPLICATE KEY UPDATE a=a+1"
67
//     *
68
//     * @param string $column
69
//     * @param mixed $value
70
//     * @return \PhpBoot\DB\rules\basic\ExecRule
71
//     */
72
//    public function onDuplicateKeyUpdate($column, $value) {
73
//        $this->impl->set($this->context, $column, $value);
74
//        return new ExecRule($this->context);
75
//    }
76
77
//    /**
78
//     *
79
//     * insertInto('table')
80
//     *      ->values(['a'=>1, 'b'=>Sql::raw('now()')])
81
//     *      ->onDuplicateKeyUpdateArgs(['a'=>Sql::raw('a+1')])
82
//     *  => "INSERT INTO table(a,b) VALUES(1,now()) ON DUPLICATE KEY UPDATE a=a+1"
83
//     *
84
//     * @param string $column
85
//     * @param mixed $value
86
//     * @return \PhpBoot\DB\rules\basic\ExecRule
87
//     */
88
//    public function onDuplicateKeyUpdateArgs($values) {
89
//        $this->impl->setArgs($this->context, $values);
90
//        return new ExecRule($this->context);
91
//    }
92
93
    /**
94
     *
95
     *  insertInto('table')
96
     *      ->values(['a'=>1, 'b'=>Sql::raw('now()')])
97
     *      ->onDuplicateKeyUpdate(['a'=>Sql::raw('a+1')])
98
     *  => "INSERT INTO table(a,b) VALUES(1,now()) ON DUPLICATE KEY UPDATE a=a+1"
99
     *
100
     * insertInto('table')
101
     *      ->values(['a'=>1, 'b'=>Sql::raw('now()')])
102
     *      ->onDuplicateKeyUpdate('a=a+1')
103
     *  => "INSERT INTO table(a,b) VALUES(1,now()) ON DUPLICATE KEY UPDATE a=a+1"
104
     *
105
     * @param string $column
0 ignored issues
show
There is no parameter named $column. Was it maybe removed?

This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.

Consider the following example. The parameter $italy is not defined by the method finale(...).

/**
 * @param array $germany
 * @param array $island
 * @param array $italy
 */
function finale($germany, $island) {
    return "2:1";
}

The most likely cause is that the parameter was removed, but the annotation was not.

Loading history...
106
     * @param mixed $value
0 ignored issues
show
There is no parameter named $value. Was it maybe removed?

This check looks for PHPDoc comments describing methods or function parameters that do not exist on the corresponding method or function.

Consider the following example. The parameter $italy is not defined by the method finale(...).

/**
 * @param array $germany
 * @param array $island
 * @param array $italy
 */
function finale($germany, $island) {
    return "2:1";
}

The most likely cause is that the parameter was removed, but the annotation was not.

Loading history...
107
     * @return \PhpBoot\DB\rules\basic\ExecRule
108
     */
109 1
    public function onDuplicateKeyUpdate($expr, $_=null) {
0 ignored issues
show
The parameter $_ 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...
110 1
        $this->impl->set($this->context, $expr, array_slice(func_get_args(), 1));
111 1
        return new ExecRule($this->context);
112
    }
113
    private $impl;
114
}