Issues (439)

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/UpdateAction.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 Spatie\SchemaOrg;
4
5
use \Spatie\SchemaOrg\Contracts\UpdateActionContract;
6
use \Spatie\SchemaOrg\Contracts\ActionContract;
7
use \Spatie\SchemaOrg\Contracts\ThingContract;
8
9
/**
10
 * The act of managing by changing/editing the state of the object.
11
 *
12
 * @see http://schema.org/UpdateAction
13
 *
14
 */
15 View Code Duplication
class UpdateAction extends BaseType implements UpdateActionContract, ActionContract, ThingContract
0 ignored issues
show
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
16
{
17
    /**
18
     * Indicates the current disposition of the Action.
19
     *
20
     * @param \Spatie\SchemaOrg\Contracts\ActionStatusTypeContract|\Spatie\SchemaOrg\Contracts\ActionStatusTypeContract[] $actionStatus
21
     *
22
     * @return static
23
     *
24
     * @see http://schema.org/actionStatus
25
     */
26
    public function actionStatus($actionStatus)
27
    {
28
        return $this->setProperty('actionStatus', $actionStatus);
29
    }
30
31
    /**
32
     * An additional type for the item, typically used for adding more specific
33
     * types from external vocabularies in microdata syntax. This is a
34
     * relationship between something and a class that the thing is in. In RDFa
35
     * syntax, it is better to use the native RDFa syntax - the 'typeof'
36
     * attribute - for multiple types. Schema.org tools may have only weaker
37
     * understanding of extra types, in particular those defined externally.
38
     *
39
     * @param string|string[] $additionalType
40
     *
41
     * @return static
42
     *
43
     * @see http://schema.org/additionalType
44
     */
45
    public function additionalType($additionalType)
46
    {
47
        return $this->setProperty('additionalType', $additionalType);
48
    }
49
50
    /**
51
     * The direct performer or driver of the action (animate or inanimate). e.g.
52
     * *John* wrote a book.
53
     *
54
     * @param \Spatie\SchemaOrg\Contracts\OrganizationContract|\Spatie\SchemaOrg\Contracts\OrganizationContract[]|\Spatie\SchemaOrg\Contracts\PersonContract|\Spatie\SchemaOrg\Contracts\PersonContract[] $agent
55
     *
56
     * @return static
57
     *
58
     * @see http://schema.org/agent
59
     */
60
    public function agent($agent)
61
    {
62
        return $this->setProperty('agent', $agent);
63
    }
64
65
    /**
66
     * An alias for the item.
67
     *
68
     * @param string|string[] $alternateName
69
     *
70
     * @return static
71
     *
72
     * @see http://schema.org/alternateName
73
     */
74
    public function alternateName($alternateName)
75
    {
76
        return $this->setProperty('alternateName', $alternateName);
77
    }
78
79
    /**
80
     * A sub property of object. The collection target of the action.
81
     *
82
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $collection
83
     *
84
     * @return static
85
     *
86
     * @see http://schema.org/collection
87
     */
88
    public function collection($collection)
89
    {
90
        return $this->setProperty('collection', $collection);
91
    }
92
93
    /**
94
     * A description of the item.
95
     *
96
     * @param string|string[] $description
97
     *
98
     * @return static
99
     *
100
     * @see http://schema.org/description
101
     */
102
    public function description($description)
103
    {
104
        return $this->setProperty('description', $description);
105
    }
106
107
    /**
108
     * A sub property of description. A short description of the item used to
109
     * disambiguate from other, similar items. Information from other properties
110
     * (in particular, name) may be necessary for the description to be useful
111
     * for disambiguation.
112
     *
113
     * @param string|string[] $disambiguatingDescription
114
     *
115
     * @return static
116
     *
117
     * @see http://schema.org/disambiguatingDescription
118
     */
119
    public function disambiguatingDescription($disambiguatingDescription)
120
    {
121
        return $this->setProperty('disambiguatingDescription', $disambiguatingDescription);
122
    }
123
124
    /**
125
     * The endTime of something. For a reserved event or service (e.g.
126
     * FoodEstablishmentReservation), the time that it is expected to end. For
127
     * actions that span a period of time, when the action was performed. e.g.
128
     * John wrote a book from January to *December*. For media, including audio
129
     * and video, it's the time offset of the end of a clip within a larger
130
     * file.
131
     * 
132
     * Note that Event uses startDate/endDate instead of startTime/endTime, even
133
     * when describing dates with times. This situation may be clarified in
134
     * future revisions.
135
     *
136
     * @param \DateTimeInterface|\DateTimeInterface[] $endTime
137
     *
138
     * @return static
139
     *
140
     * @see http://schema.org/endTime
141
     */
142
    public function endTime($endTime)
143
    {
144
        return $this->setProperty('endTime', $endTime);
145
    }
146
147
    /**
148
     * For failed actions, more information on the cause of the failure.
149
     *
150
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $error
151
     *
152
     * @return static
153
     *
154
     * @see http://schema.org/error
155
     */
156
    public function error($error)
157
    {
158
        return $this->setProperty('error', $error);
159
    }
160
161
    /**
162
     * The identifier property represents any kind of identifier for any kind of
163
     * [[Thing]], such as ISBNs, GTIN codes, UUIDs etc. Schema.org provides
164
     * dedicated properties for representing many of these, either as textual
165
     * strings or as URL (URI) links. See [background
166
     * notes](/docs/datamodel.html#identifierBg) for more details.
167
     *
168
     * @param \Spatie\SchemaOrg\Contracts\PropertyValueContract|\Spatie\SchemaOrg\Contracts\PropertyValueContract[]|string|string[] $identifier
169
     *
170
     * @return static
171
     *
172
     * @see http://schema.org/identifier
173
     */
174
    public function identifier($identifier)
175
    {
176
        return $this->setProperty('identifier', $identifier);
177
    }
178
179
    /**
180
     * An image of the item. This can be a [[URL]] or a fully described
181
     * [[ImageObject]].
182
     *
183
     * @param \Spatie\SchemaOrg\Contracts\ImageObjectContract|\Spatie\SchemaOrg\Contracts\ImageObjectContract[]|string|string[] $image
184
     *
185
     * @return static
186
     *
187
     * @see http://schema.org/image
188
     */
189
    public function image($image)
190
    {
191
        return $this->setProperty('image', $image);
192
    }
193
194
    /**
195
     * The object that helped the agent perform the action. e.g. John wrote a
196
     * book with *a pen*.
197
     *
198
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $instrument
199
     *
200
     * @return static
201
     *
202
     * @see http://schema.org/instrument
203
     */
204
    public function instrument($instrument)
205
    {
206
        return $this->setProperty('instrument', $instrument);
207
    }
208
209
    /**
210
     * The location of for example where the event is happening, an organization
211
     * is located, or where an action takes place.
212
     *
213
     * @param \Spatie\SchemaOrg\Contracts\PlaceContract|\Spatie\SchemaOrg\Contracts\PlaceContract[]|\Spatie\SchemaOrg\Contracts\PostalAddressContract|\Spatie\SchemaOrg\Contracts\PostalAddressContract[]|string|string[] $location
214
     *
215
     * @return static
216
     *
217
     * @see http://schema.org/location
218
     */
219
    public function location($location)
220
    {
221
        return $this->setProperty('location', $location);
222
    }
223
224
    /**
225
     * Indicates a page (or other CreativeWork) for which this thing is the main
226
     * entity being described. See [background
227
     * notes](/docs/datamodel.html#mainEntityBackground) for details.
228
     *
229
     * @param \Spatie\SchemaOrg\Contracts\CreativeWorkContract|\Spatie\SchemaOrg\Contracts\CreativeWorkContract[]|string|string[] $mainEntityOfPage
230
     *
231
     * @return static
232
     *
233
     * @see http://schema.org/mainEntityOfPage
234
     */
235
    public function mainEntityOfPage($mainEntityOfPage)
236
    {
237
        return $this->setProperty('mainEntityOfPage', $mainEntityOfPage);
238
    }
239
240
    /**
241
     * The name of the item.
242
     *
243
     * @param string|string[] $name
244
     *
245
     * @return static
246
     *
247
     * @see http://schema.org/name
248
     */
249
    public function name($name)
250
    {
251
        return $this->setProperty('name', $name);
252
    }
253
254
    /**
255
     * The object upon which the action is carried out, whose state is kept
256
     * intact or changed. Also known as the semantic roles patient, affected or
257
     * undergoer (which change their state) or theme (which doesn't). e.g. John
258
     * read *a book*.
259
     *
260
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $object
261
     *
262
     * @return static
263
     *
264
     * @see http://schema.org/object
265
     */
266
    public function object($object)
267
    {
268
        return $this->setProperty('object', $object);
269
    }
270
271
    /**
272
     * Other co-agents that participated in the action indirectly. e.g. John
273
     * wrote a book with *Steve*.
274
     *
275
     * @param \Spatie\SchemaOrg\Contracts\OrganizationContract|\Spatie\SchemaOrg\Contracts\OrganizationContract[]|\Spatie\SchemaOrg\Contracts\PersonContract|\Spatie\SchemaOrg\Contracts\PersonContract[] $participant
276
     *
277
     * @return static
278
     *
279
     * @see http://schema.org/participant
280
     */
281
    public function participant($participant)
282
    {
283
        return $this->setProperty('participant', $participant);
284
    }
285
286
    /**
287
     * Indicates a potential Action, which describes an idealized action in
288
     * which this thing would play an 'object' role.
289
     *
290
     * @param \Spatie\SchemaOrg\Contracts\ActionContract|\Spatie\SchemaOrg\Contracts\ActionContract[] $potentialAction
291
     *
292
     * @return static
293
     *
294
     * @see http://schema.org/potentialAction
295
     */
296
    public function potentialAction($potentialAction)
297
    {
298
        return $this->setProperty('potentialAction', $potentialAction);
299
    }
300
301
    /**
302
     * The result produced in the action. e.g. John wrote *a book*.
303
     *
304
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $result
305
     *
306
     * @return static
307
     *
308
     * @see http://schema.org/result
309
     */
310
    public function result($result)
311
    {
312
        return $this->setProperty('result', $result);
313
    }
314
315
    /**
316
     * URL of a reference Web page that unambiguously indicates the item's
317
     * identity. E.g. the URL of the item's Wikipedia page, Wikidata entry, or
318
     * official website.
319
     *
320
     * @param string|string[] $sameAs
321
     *
322
     * @return static
323
     *
324
     * @see http://schema.org/sameAs
325
     */
326
    public function sameAs($sameAs)
327
    {
328
        return $this->setProperty('sameAs', $sameAs);
329
    }
330
331
    /**
332
     * The startTime of something. For a reserved event or service (e.g.
333
     * FoodEstablishmentReservation), the time that it is expected to start. For
334
     * actions that span a period of time, when the action was performed. e.g.
335
     * John wrote a book from *January* to December. For media, including audio
336
     * and video, it's the time offset of the start of a clip within a larger
337
     * file.
338
     * 
339
     * Note that Event uses startDate/endDate instead of startTime/endTime, even
340
     * when describing dates with times. This situation may be clarified in
341
     * future revisions.
342
     *
343
     * @param \DateTimeInterface|\DateTimeInterface[] $startTime
344
     *
345
     * @return static
346
     *
347
     * @see http://schema.org/startTime
348
     */
349
    public function startTime($startTime)
350
    {
351
        return $this->setProperty('startTime', $startTime);
352
    }
353
354
    /**
355
     * A CreativeWork or Event about this Thing.
356
     *
357
     * @param \Spatie\SchemaOrg\Contracts\CreativeWorkContract|\Spatie\SchemaOrg\Contracts\CreativeWorkContract[]|\Spatie\SchemaOrg\Contracts\EventContract|\Spatie\SchemaOrg\Contracts\EventContract[] $subjectOf
358
     *
359
     * @return static
360
     *
361
     * @see http://schema.org/subjectOf
362
     */
363
    public function subjectOf($subjectOf)
364
    {
365
        return $this->setProperty('subjectOf', $subjectOf);
366
    }
367
368
    /**
369
     * Indicates a target EntryPoint for an Action.
370
     *
371
     * @param \Spatie\SchemaOrg\Contracts\EntryPointContract|\Spatie\SchemaOrg\Contracts\EntryPointContract[] $target
372
     *
373
     * @return static
374
     *
375
     * @see http://schema.org/target
376
     */
377
    public function target($target)
378
    {
379
        return $this->setProperty('target', $target);
380
    }
381
382
    /**
383
     * A sub property of object. The collection target of the action.
384
     *
385
     * @param \Spatie\SchemaOrg\Contracts\ThingContract|\Spatie\SchemaOrg\Contracts\ThingContract[] $targetCollection
386
     *
387
     * @return static
388
     *
389
     * @see http://schema.org/targetCollection
390
     */
391
    public function targetCollection($targetCollection)
392
    {
393
        return $this->setProperty('targetCollection', $targetCollection);
394
    }
395
396
    /**
397
     * URL of the item.
398
     *
399
     * @param string|string[] $url
400
     *
401
     * @return static
402
     *
403
     * @see http://schema.org/url
404
     */
405
    public function url($url)
406
    {
407
        return $this->setProperty('url', $url);
408
    }
409
410
}
411