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 (74)

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.

tests/src/Period/MonthTest.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 Tests\COG\ChronoShifter\Period;
4
5
use COG\ChronoShifter\Period\Month;
6
7
/**
8
 * @author Kristjan Siimson <[email protected]>
9
 * @package Period\Test
10
 */
11
class MonthTest extends \PHPUnit_Framework_TestCase
12
{
13
    /**
14
     * @dataProvider createMonthByAnyDateInRangeProvider
15
     * @param string $date
16
     * @param string $startDate
17
     * @param string $endDate
18
     */
19
    public function testCreateMonthByAnyDateInRange($date, $startDate, $endDate)
20
    {
21
        $month = new Month($date);
22
23
        $this->assertEquals($startDate, $month->getStartDate());
24
        $this->assertEquals($endDate, $month->getEndDate());
25
    }
26
27
    /**
28
     * @return array
29
     */
30
    public function createMonthByAnyDateInRangeProvider()
31
    {
32
        return array(
33
            array('1999-12-31', '1999-12-01', '1999-12-31'),
34
            array('2000-01-01', '2000-01-01', '2000-01-31'),
35
            array('2000-02-15', '2000-02-01', '2000-02-29')
36
        );
37
    }
38
39
    /**
40
     * @dataProvider nextMonthProvider
41
     * @param string $date
42
     * @param string $startDate
43
     * @param string $endDate
44
     */
45
    public function testNextMonth($date, $startDate, $endDate)
46
    {
47
        $month = new Month($date);
48
        $month->next();
49
50
        $this->assertEquals($startDate, $month->getStartDate());
51
        $this->assertEquals($endDate, $month->getEndDate());
52
    }
53
54
    /**
55
     * @return array
56
     */
57 View Code Duplication
    public function nextMonthProvider()
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...
58
    {
59
        return array(
60
            array('1999-11-30', '1999-12-01', '1999-12-31'),
61
            array('1999-12-31', '2000-01-01', '2000-01-31'),
62
            array('2000-01-15', '2000-02-01', '2000-02-29'),
63
            array('2000-02-01', '2000-03-01', '2000-03-31'),
64
            array('2000-03-01', '2000-04-01', '2000-04-30'),
65
            array('2000-04-01', '2000-05-01', '2000-05-31'),
66
            array('2000-05-01', '2000-06-01', '2000-06-30'),
67
            array('2000-06-01', '2000-07-01', '2000-07-31'),
68
            array('2000-07-01', '2000-08-01', '2000-08-31'),
69
            array('2000-08-01', '2000-09-01', '2000-09-30'),
70
            array('2000-09-01', '2000-10-01', '2000-10-31'),
71
            array('2000-10-01', '2000-11-01', '2000-11-30'),
72
            array('2000-11-01', '2000-12-01', '2000-12-31'),
73
            array('2000-12-01', '2001-01-01', '2001-01-31'),
74
        );
75
    }
76
77
    /**
78
     * @dataProvider previousMonthProvider
79
     * @param string $date
80
     * @param string $startDate
81
     * @param string $endDate
82
     */
83 View Code Duplication
    public function testPreviousMonth($date, $startDate, $endDate)
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...
84
    {
85
        $month = new Month($date);
86
        $month->previous();
87
88
        $this->assertEquals($startDate, $month->getStartDate());
89
        $this->assertEquals($endDate, $month->getEndDate());
90
    }
91
92
    /**
93
     * @return array
94
     */
95 View Code Duplication
    public function previousMonthProvider()
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...
96
    {
97
        return array(
98
            array('1999-11-30', '1999-10-01', '1999-10-31'),
99
            array('1999-12-31', '1999-11-01', '1999-11-30'),
100
            array('2000-01-15', '1999-12-01', '1999-12-31'),
101
            array('2000-02-01', '2000-01-01', '2000-01-31'),
102
            array('2000-03-01', '2000-02-01', '2000-02-29'),
103
            array('2000-04-01', '2000-03-01', '2000-03-31'),
104
            array('2000-05-01', '2000-04-01', '2000-04-30'),
105
            array('2000-06-01', '2000-05-01', '2000-05-31'),
106
            array('2000-07-01', '2000-06-01', '2000-06-30'),
107
            array('2000-08-01', '2000-07-01', '2000-07-31'),
108
            array('2000-09-01', '2000-08-01', '2000-08-31'),
109
            array('2000-10-01', '2000-09-01', '2000-09-30'),
110
            array('2000-11-01', '2000-10-01', '2000-10-31'),
111
            array('2000-12-01', '2000-11-01', '2000-11-30')
112
        );
113
    }
114
115
    public function testGetNumberOfDays()
116
    {
117
        $month = new Month('2015-02-15');
118
        $this->assertEquals(27, $month->getNumberOfDays());
119
    }
120
}
121