Issues (8)

Security Analysis    no request data  

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/Criteria/EntryCriteria.php (1 issue)

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 Del\Expenses\Criteria;
4
5
use DateTime;
6
use Del\Common\Criteria as CommonCriteria;
7
8
9
class EntryCriteria extends CommonCriteria
0 ignored issues
show
Deprecated Code introduced by
The class Del\Common\Criteria has been deprecated with message: use Del\Common\Criteria\AbstractCriteria

This class, trait or interface has been deprecated. The supplier of the file has supplied an explanatory message.

The explanatory message should give you some clue as to whether and when the type will be removed from the class and what other constant to use instead.

Loading history...
10
{
11
    const ORDER_AMOUNT          = 'amount';
12
    const ORDER_CATEGORY        = 'category';
13
    const ORDER_DATE            = 'date';
14
    const ORDER_DESCRIPTION     = 'description';
15
    const ORDER_ID              = 'id';
16
    const ORDER_NOTE            = 'note';
17
    const ORDER_TYPE            = 'type';
18
    const ORDER_USERID          = 'userId';
19
20
    protected $id;
21
    protected $userId;
22
    protected $date;
23
    protected $dateRange;
24
    protected $amount;
25
    protected $category;
26
    protected $description;
27
    protected $note;
28
    protected $type;
29
30
    /**
31
     * @return int
32
     */
33 2
    public function getId()
34
    {
35 2
        return $this->id;
36
    }
37
38
    /**
39
     * @param $id
40
     * @return $this
41
     */
42 2
    public function setId($id)
43
    {
44 2
        $this->id = (int) $id;
45 2
        return $this;
46
    }
47
48
    /**
49
     * @return bool
50
     */
51 3
    public function hasId()
52
    {
53 3
        return $this->id != null;
54
    }
55
56
    /**
57
     * @return int
58
     */
59
    public function getUserId()
60
    {
61
        return $this->userId;
62
    }
63
64
    /**
65
     * @param $id
66
     * @return $this
67
     */
68
    public function setUserId($id)
69
    {
70
        $this->userId = (int) $id;
71
        return $this;
72
    }
73
74
    /**
75
     * @return bool
76
     */
77 3
    public function hasUserId()
78
    {
79 3
        return $this->userId != null;
80
    }
81
82
    /**
83
     * @return mixed
84
     */
85 1
    public function getDate()
86
    {
87 1
        return $this->date;
88
    }
89
90
    /**
91
     * @param mixed $date
92
     * @return EntryCriteria
93
     */
94 1
    public function setDate($date)
95
    {
96 1
        $this->date = $date;
97 1
        return $this;
98
    }
99
100
    /**
101
     * @return bool
102
     */
103 3
    public function hasDateRange()
104
    {
105 3
        return $this->dateRange != null;
106
    }
107
108
    /**
109
     * @return mixed
110
     */
111 1
    public function getDateRange()
112
    {
113 1
        return $this->dateRange;
114
    }
115
116
    /**
117
     * @param string $fromDate
118
     * @param string $toDate
119
     * @return $this
120
     */
121 1
    public function setDateRange($fromDate, $toDate)
122
    {
123 1
        $this->dateRange = [
124 1
            $fromDate, $toDate
125
        ];
126 1
        return $this;
127
    }
128
129
    /**
130
     * @return bool
131
     */
132 3
    public function hasDate()
133
    {
134 3
        return $this->date != null;
135
    }
136
137
    /**
138
     * @return mixed
139
     */
140
    public function getAmount()
141
    {
142
        return $this->amount;
143
    }
144
145
    /**
146
     * @param mixed $amount
147
     * @return EntryCriteria
148
     */
149
    public function setAmount($amount)
150
    {
151
        $this->amount = $amount;
152
        return $this;
153
    }
154
155
    /**
156
     * @return bool
157
     */
158 3
    public function hasAmount()
159
    {
160 3
        return $this->amount != null;
161
    }
162
163
    /**
164
     * @return mixed
165
     */
166 1
    public function getCategory()
167
    {
168 1
        return $this->category;
169
    }
170
171
    /**
172
     * @param mixed $category
173
     * @return EntryCriteria
174
     */
175 1
    public function setCategory($category)
176
    {
177 1
        $this->category = $category;
178 1
        return $this;
179
    }
180
181
    /**
182
     * @return bool
183
     */
184 3
    public function hasCategory()
185
    {
186 3
        return $this->category != null;
187
    }
188
189
    /**
190
     * @return mixed
191
     */
192 1
    public function getDescription()
193
    {
194 1
        return $this->description;
195
    }
196
197
    /**
198
     * @param mixed $description
199
     * @return EntryCriteria
200
     */
201 1
    public function setDescription($description)
202
    {
203 1
        $this->description = $description;
204 1
        return $this;
205
    }
206
207
    /**
208
     * @return bool
209
     */
210 3
    public function hasDescription()
211
    {
212 3
        return $this->description != null;
213
    }
214
215
    /**
216
     * @return mixed
217
     */
218 1
    public function getNote()
219
    {
220 1
        return $this->note;
221
    }
222
223
    /**
224
     * @param mixed $note
225
     * @return EntryCriteria
226
     */
227 1
    public function setNote($note)
228
    {
229 1
        $this->note = $note;
230 1
        return $this;
231
    }
232
233
    /**
234
     * @return bool
235
     */
236 3
    public function hasNote()
237
    {
238 3
        return $this->note != null;
239
    }
240
241
    /**
242
     * @return mixed
243
     */
244 1
    public function getType()
245
    {
246 1
        return $this->type;
247
    }
248
249
    /**
250
     * @param mixed $type
251
     * @return EntryCriteria
252
     */
253 1
    public function setType($type)
254
    {
255 1
        $this->type = $type;
256 1
        return $this;
257
    }
258
259
    /**
260
     * @return bool
261
     */
262 3
    public function hasType()
263
    {
264 3
        return $this->type != null;
265
    }
266
267
268
}