Issues (5)

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/Adapter/NullCacheItemPool.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
namespace Psr6NullCache\Adapter;
3
4
use Psr\Cache\CacheItemPoolInterface;
5
use Psr\Cache\CacheItemInterface;
6
use Psr6NullCache\CacheItem;
7
8
final class NullCacheItemPool implements CacheItemPoolInterface
9
{
10
11
    /**
12
     * Returns a Cache Item representing the specified key.
13
     *
14
     * This method must always return a CacheItemInterface object, even in case of
15
     * a cache miss. It MUST NOT return null.
16
     *
17
     * @param string $key
18
     *            The key for which to return the corresponding Cache Item.
19
     *            
20
     * @throws InvalidArgumentException If the $key string is not a legal value a \Psr\Cache\InvalidArgumentException
21
     *         MUST be thrown.
22
     *        
23
     * @return CacheItemInterface
24
     */
25
    public function getItem($key)
26
    {
27
        return new CacheItem($key, null, false);
28
    }
29
30
    /**
31
     * Returns a traversable set of cache items.
32
     *
33
     * @param array $keys
34
     *            An indexed array of keys of items to retrieve.
35
     *            
36
     * @throws InvalidArgumentException If any of the keys in $keys are not a legal value a \Psr\Cache\InvalidArgumentException
37
     *         MUST be thrown.
38
     *        
39
     * @return array|\Traversable A traversable collection of Cache Items keyed by the cache keys of
40
     *         each item. A Cache item will be returned for each key, even if that
41
     *         key is not found. However, if no keys are specified then an empty
42
     *         traversable MUST be returned instead.
43
     */
44 View Code Duplication
    public function getItems(array $keys = [])
0 ignored issues
show
This method 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...
45
    {
46
        $result = [];
47
        
48
        foreach ($keys as $key) {
49
            $result[$key] = $this->getItem($key);
50
        }
51
        
52
        return $result;
53
    }
54
55
    /**
56
     * Confirms if the cache contains specified cache item.
57
     *
58
     * Note: This method MAY avoid retrieving the cached value for performance reasons.
59
     * This could result in a race condition with CacheItemInterface::get(). To avoid
60
     * such situation use CacheItemInterface::isHit() instead.
61
     *
62
     * @param string $key
63
     *            The key for which to check existence.
64
     *            
65
     * @throws InvalidArgumentException If the $key string is not a legal value a \Psr\Cache\InvalidArgumentException
66
     *         MUST be thrown.
67
     *        
68
     * @return bool True if item exists in the cache, false otherwise.
69
     */
70
    public function hasItem($key)
71
    {
72
        return false;
73
    }
74
75
    /**
76
     * Deletes all items in the pool.
77
     *
78
     * @return bool True if the pool was successfully cleared. False if there was an error.
79
     */
80
    public function clear()
81
    {
82
        return true;
83
    }
84
85
    /**
86
     * Removes the item from the pool.
87
     *
88
     * @param string $key
89
     *            The key for which to delete
90
     *            
91
     * @throws InvalidArgumentException If the $key string is not a legal value a \Psr\Cache\InvalidArgumentException
92
     *         MUST be thrown.
93
     *        
94
     * @return bool True if the item was successfully removed. False if there was an error.
95
     */
96
    public function deleteItem($key)
97
    {
98
        return true;
99
    }
100
101
    /**
102
     * Removes multiple items from the pool.
103
     *
104
     * @param array $keys
105
     *            An array of keys that should be removed from the pool.
106
     *            
107
     * @throws InvalidArgumentException If any of the keys in $keys are not a legal value a \Psr\Cache\InvalidArgumentException
108
     *         MUST be thrown.
109
     *        
110
     * @return bool True if the items were successfully removed. False if there was an error.
111
     */
112
    public function deleteItems(array $keys)
113
    {
114
        return true;
115
    }
116
117
    /**
118
     * Persists a cache item immediately.
119
     *
120
     * @param CacheItemInterface $item
121
     *            The cache item to save.
122
     *            
123
     * @return bool True if the item was successfully persisted. False if there was an error.
124
     */
125
    public function save(CacheItemInterface $item)
126
    {
127
        return true;
128
    }
129
130
    /**
131
     * Sets a cache item to be persisted later.
132
     *
133
     * @param CacheItemInterface $item
134
     *            The cache item to save.
135
     *            
136
     * @return bool False if the item could not be queued or if a commit was attempted and failed. True otherwise.
137
     */
138
    public function saveDeferred(CacheItemInterface $item)
139
    {
140
        return true;
141
    }
142
143
    /**
144
     * Persists any deferred cache items.
145
     *
146
     * @return bool True if all not-yet-saved items were successfully saved or there were none. False otherwise.
147
     */
148
    public function commit()
149
    {
150
        return true;
151
    }
152
}
153