Issues (1704)

Branch: master

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.

Entity/APIBusinessEntity.php (3 issues)

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
namespace Victoire\Bundle\APIBusinessEntityBundle\Entity;
4
5
use Doctrine\ORM\Mapping as ORM;
6
use Victoire\Bundle\BusinessEntityBundle\Entity\BusinessEntity;
7
8
/**
9
 * The API business Entity.
10
 *
11
 * @ORM\Entity(repositoryClass="Victoire\Bundle\ORMBusinessEntityBundle\Entity\ORMBusinessEntityRepository")
12
 */
13
class APIBusinessEntity extends BusinessEntity
14
{
15
    const TYPE = 'api';
16
17
    /**
18
     * @var string
19
     *
20
     * @ORM\Column(name="resource", type="string", length=255)
21
     */
22
    protected $resource;
23
24
    /**
25
     * @var string
26
     *
27
     * @ORM\Column(name="getMethod", type="text")
28
     */
29
    protected $getMethod;
30
31
    /**
32
     * @var string
33
     *
34
     * @ORM\Column(name="listMethod", type="text")
35
     */
36
    protected $listMethod;
37
38
    /**
39
     * @var string
40
     *
41
     * @ORM\Column(name="pagerParameter", type="text")
42
     */
43
    protected $pagerParameter;
44
45
    /**
46
     * @var APIEndpoint
47
     *
48
     * @ORM\ManyToOne(targetEntity="APIEndpoint")
49
     * @ORM\JoinColumn(name="endpoint_id", referencedColumnName="id", onDelete="SET NULL"))
50
     */
51
    protected $endpoint;
52
53
    /**
54
     * @return string
55
     */
56
    public function getResource()
57
    {
58
        return $this->resource;
59
    }
60
61
    /**
62
     * @param string $resource
63
     */
64
    public function setResource($resource)
65
    {
66
        $this->resource = $resource;
67
    }
68
69
    /**
70
     * @return APIEndpoint
71
     */
72
    public function getEndpoint()
73
    {
74
        return $this->endpoint;
75
    }
76
77
    /**
78
     * @param APIEndpoint $endpoint
79
     */
80
    public function setEndpoint($endpoint)
81
    {
82
        $this->endpoint = $endpoint;
83
    }
84
85
    public function getType()
0 ignored issues
show
Missing function doc comment
Loading history...
86
    {
87
        return self::TYPE;
88
    }
89
90
    /**
91
     * @return string
92
     */
93
    public function getGetMethod()
94
    {
95
        return $this->getMethod;
96
    }
97
98
    /**
99
     * @param string $getMethod
100
     */
101
    public function setGetMethod($getMethod)
102
    {
103
        $this->getMethod = $getMethod;
104
    }
105
106
    /**
0 ignored issues
show
Doc comment for parameter "$page" missing
Loading history...
107
     * @return string
108
     */
109
    public function getListMethod($page = null)
110
    {
111
        $listMethod = $this->listMethod;
112
        if ($page) {
113
            $listMethod .= (false !== strpos($listMethod, '?') ? '&' : '?')
114
                .str_replace('{{page}}', $page, $this->pagerParameter);
0 ignored issues
show
Concat operator must not be surrounded by spaces
Loading history...
115
        }
116
117
        return $listMethod;
118
    }
119
120
    /**
121
     * @param string $listMethod
122
     */
123
    public function setListMethod($listMethod)
124
    {
125
        $this->listMethod = $listMethod;
126
    }
127
128
    /**
129
     * @return string
130
     */
131
    public function getPagerParameter()
132
    {
133
        return $this->pagerParameter;
134
    }
135
136
    /**
137
     * @param string $pagerParameter
138
     */
139
    public function setPagerParameter($pagerParameter)
140
    {
141
        $this->pagerParameter = $pagerParameter;
142
    }
143
}
144