RobDWaller / ReallySimpleJWT

Compare eba7970 ... +3 ... 8b72fbc

No flags found

Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.

e.g., #unittest #integration

#production #enterprise

#frontend #backend

Learn more about Codecov Flags here.

Showing 2 of 4 files from the diff.

@@ -110,6 +110,23 @@
Loading
110 110
        return $this;
111 111
    }
112 112
113 +
    /**
114 +
     * Validate the token's alg claim is not none.
115 +
     *
116 +
     * @throws ValidateException
117 +
     */
118 +
    public function algorithmNotNone(): Validate
119 +
    {
120 +
        if ($this->validate->algorithm(strtolower($this->parse->getAlgorithm()), ['none'])) {
121 +
            throw new ValidateException(
122 +
                'Algorithm claim should not be none.',
123 +
                14
124 +
            );
125 +
        }
126 +
127 +
        return $this;
128 +
    }
129 +
113 130
    /**
114 131
     * Validate the JWT's signature. The signature taken from the JWT should
115 132
     * match a new one generated from the JWT header and payload, and secret.

@@ -135,6 +135,7 @@
Loading
135 135
136 136
        try {
137 137
            $validate->structure();
138 +
            $validate->algorithmNotNone();
138 139
            $validate->signature();
139 140
            return true;
140 141
        } catch (ValidateException $e) {

Everything is accounted for!

No changes detected that need to be reviewed.
What changes does Codecov check for?
Lines, not adjusted in diff, that have changed coverage data.
Files that introduced coverage data that had none before.
Files that have missing coverage data that once were tracked.
Files Complexity Coverage
src ø 100.00%
Project Totals (13 files) 127 100.00%
Loading