The following document contains the results of PMD 4.3.
| Violation | Line |
|---|---|
| The class 'IssuerServlet' has a Cyclomatic Complexity of 7 (Highest = 21). | 79 - 422 |
| Parameter 'config' is not assigned and could be declared final | 116 |
| Local variable 'storage' could be declared final | 122 |
| Local variable 'specStore' could be declared final | 123 |
| Local variable 'eidStore' could be declared final | 124 |
| Local variable 'tempStore' could be declared final | 125 |
| Local variable 'issuerStore' could be declared final | 126 |
| Local variable 'verifierStore' could be declared final | 127 |
| The method 'doGet' has a Cyclomatic Complexity of 15. | 143 - 213 |
| Parameter 'req' is not assigned and could be declared final | 143 |
| Parameter 'resp' is not assigned and could be declared final | 143 |
| Local variable 'ctx' could be declared final | 146 |
| Local variable 'fLoc' could be declared final | 149 |
| Avoid if (x != y) ..; else ..; | 155 - 210 |
| Local variable 'structId' could be declared final | 160 - 162 |
| Avoid if (x != y) ..; else ..; | 163 - 191 |
| Avoid using Literals in Conditional Statements | 163 |
| Found 'DD'-anomaly for variable 'credId' (lines '164'-'166'). | 164 - 166 |
| Avoid if (x != y) ..; else ..; | 172 - 188 |
| Avoid using Literals in Conditional Statements | 172 |
| Local variable 'credIdUri' could be declared final | 174 |
| Avoid if (x != y) ..; else ..; | 175 - 185 |
| Avoid using Literals in Conditional Statements | 175 |
| Local variable 'sreq' could be declared final | 177 - 178 |
| Avoid using Literals in Conditional Statements | 179 |
| Local variable 'rctx' could be declared final | 180 |
| Local variable 'rreq' could be declared final | 196 - 197 |
| Avoid using Literals in Conditional Statements | 198 |
| Local variable 'red' could be declared final | 199 |
| The method 'doPost' has a Cyclomatic Complexity of 21. | 219 - 274 |
| Parameter 'req' is not assigned and could be declared final | 219 |
| Parameter 'resp' is not assigned and could be declared final | 219 |
| These nested if statements could be combined | 236 - 246 |
| Local variable 'sresp' could be declared final | 240 |
| Avoid using Literals in Conditional Statements | 241 |
| These nested if statements could be combined | 251 - 255 |
| Local variable 'res' could be declared final | 252 |
| These nested if statements could be combined | 260 - 266 |
| Local variable 'vresp' could be declared final | 261 |
| Avoid using Literals in Conditional Statements | 262 |
| Parameter 'ctx' is not assigned and could be declared final | 286 |
| Parameter 'req' is not assigned and could be declared final | 286 |
| Parameter 'resp' is not assigned and could be declared final | 286 |
| Found 'DD'-anomaly for variable 'result' (lines '289'-'290'). | 289 - 290 |
| Parameter 'code' is not assigned and could be declared final | 305 |
| Parameter 'resp' is not assigned and could be declared final | 305 |
| Found 'DD'-anomaly for variable 'out' (lines '310'-'313'). | 310 - 313 |
| Found 'DD'-anomaly for variable 'out' (lines '310'-'316'). | 310 - 316 |
| Found 'DD'-anomaly for variable 'out' (lines '310'-'319'). | 310 - 319 |
| Found 'DD'-anomaly for variable 'out' (lines '310'-'322'). | 310 - 322 |
| Found 'DD'-anomaly for variable 'out' (lines '310'-'325'). | 310 - 325 |
| Switch statements should have a default label | 311 - 327 |
| Avoid unused private methods such as 'sendSuccess(HttpServletResponse,String)'. | 340 |
| Parameter 'result' is not assigned and could be declared final | 340 |
| Parameter 'resp' is not assigned and could be declared final | 340 |
| Parameter 'fLoc' is not assigned and could be declared final | 357 |
| Parameter 'resp' is not assigned and could be declared final | 357 |
| Found 'DD'-anomaly for variable 'url' (lines '362'-'364'). | 362 - 364 |
| Found 'DD'-anomaly for variable 'reader' (lines '368'-'370'). | 368 - 370 |
| Found 'DD'-anomaly for variable 'reader' (lines '368'-'372'). | 368 - 372 |
| Avoid if (x != y) ..; else ..; | 369 - 373 |
| Avoid using Literals in Conditional Statements | 369 |
| Avoid using Literals in Conditional Statements | 374 |
| Found 'DD'-anomaly for variable 'line' (lines '375'-'376'). | 375 - 376 |
| Avoid assignments in operands | 376 |
| Found 'DU'-anomaly for variable 'line' (lines '376'-'382'). | 376 - 382 |
| Avoid unused private methods such as 'toString(ServletInputStream)'. | 390 |
| Parameter 'is' is not assigned and could be declared final | 390 |
| Found 'DD'-anomaly for variable 'result' (lines '393'-'410'). | 393 - 410 |
| Avoid using Literals in Conditional Statements | 396 |
| Local variable 'writer' could be declared final | 397 |
| Local variable 'buffer' could be declared final | 399 |
| Local variable 'reader' could be declared final | 401 - 402 |
| Avoid assignments in operands | 404 |
| Found 'DU'-anomaly for variable 'n' (lines '404'-'420'). | 404 - 420 |
| Violation | Line |
|---|---|
| Too many fields | 66 - 523 |
| Private field 'IPK' could be made final; it is only initialized in the declaration or constructor. | 83 |
| Private field 'ISK' could be made final; it is only initialized in the declaration or constructor. | 86 |
| Private field 'SP' could be made final; it is only initialized in the declaration or constructor. | 89 |
| Private field 'GP' could be made final; it is only initialized in the declaration or constructor. | 92 |
| Private field 'VEPK' could be made final; it is only initialized in the declaration or constructor. | 95 |
| Private field 'VESK' could be made final; it is only initialized in the declaration or constructor. | 98 |
| Private field 'ISSUER_BASE' could be made final; it is only initialized in the declaration or constructor. | 101 |
| Perhaps 'ISSUER_BASE' could be replaced by a local variable. | 101 |
| Private field 'ATTRIB_SIZE' could be made final; it is only initialized in the declaration or constructor. | 104 |
| Private field 'EPOCH_LENGTH' could be made final; it is only initialized in the declaration or constructor. | 107 |
| Private field 'SPECS' could be made final; it is only initialized in the declaration or constructor. | 110 |
| Private field 'REVOC' could be made final; it is only initialized in the declaration or constructor. | 113 |
| Private field 'TEMP_DIR' could be made final; it is only initialized in the declaration or constructor. | 119 |
| Parameter 'cfg' is not assigned and could be declared final | 148 |
| Local variable 'f' could be declared final | 178 |
| Local variable 'secret' could be declared final | 180 |
| Avoid if (x != y) ..; else ..; | 183 - 188 |
| Avoid using Literals in Conditional Statements | 183 |
| Parameter 'srv' is not assigned and could be declared final | 194 |
| Parameter 'secret' is not assigned and could be declared final | 204 |
| Avoid using Literals in Conditional Statements | 205 |
| Avoid using Literals in Conditional Statements | 212 |
| Local variable 'ipkFile' could be declared final | 328 |
| Local variable 'iskFile' could be declared final | 329 |
| Local variable 'gpf' could be declared final | 339 |
| Local variable 'gpData' could be declared final | 341 |
| Local variable 'gpDataStr' could be declared final | 342 |
| Local variable 'ikp' could be declared final | 347 - 348 |
| Local variable 'ipk' could be declared final | 349 |
| Local variable 'isk' could be declared final | 350 |
| Local variable 'gp' could be declared final | 351 |
| Local variable 'sp' could be declared final | 352 |
| Use block level rather than method level synchronization | 371 - 382 |
| Parameter 'map' is not assigned and could be declared final | 371 |
| Parameter 'isOptional' is not assigned and could be declared final | 371 |
| Local variable 'dest' could be declared final | 374 |
| Local variable 'scheme' could be declared final | 375 |
| Position literals first in String comparisons | 376 |
| Local variable 'f' could be declared final | 377 |
| Use block level rather than method level synchronization | 390 - 395 |
| Parameter 'maps' is not assigned and could be declared final | 390 |
| Use block level rather than method level synchronization | 418 - 420 |
| Parameter 'id' is not assigned and could be declared final | 418 |
| Parameter 'ecode' is not assigned and could be declared final | 466 |
| Parameter 'emsg' is not assigned and could be declared final | 466 |
| Parameter 'specUri' is not assigned and could be declared final | 474 |
| Found 'DD'-anomaly for variable 'result' (lines '475'-'478'). | 475 - 478 |
| Local variable 'spec' could be declared final | 476 - 477 |
| Parameter 'specUri' is not assigned and could be declared final | 486 |
| Violation | Line |
|---|---|
| A class which only has private constructors should be final | 47 - 240 |
| Parameter 'pwd' is not assigned and could be declared final | 83 |
| Local variable 'url' could be declared final | 91 |
| Local variable 'userPass' could be declared final | 92 - 93 |
| New exception is thrown in catch block, original stack trace may be lost | 100 |
| New exception is thrown in catch block, original stack trace may be lost | 102 |
| Use block level rather than method level synchronization | 115 - 120 |
| Avoid using Literals in Conditional Statements | 117 |
| Use block level rather than method level synchronization | 129 - 136 |
| Parameter 'pwd' is not assigned and could be declared final | 129 |
| Avoid if (x != y) ..; else ..; | 131 - 134 |
| Avoid using Literals in Conditional Statements | 131 |
| Use block level rather than method level synchronization | 143 - 145 |
| Parameter 'tableName' is not assigned and could be declared final | 153 |
| Found 'DD'-anomaly for variable 'result' (lines '154'-'160'). | 154 - 160 |
| Local variable 'meta' could be declared final | 157 |
| Avoid using Literals in Conditional Statements | 158 |
| Ensure that resources like this ResultSet object are closed after use | 159 |
| Local variable 'res' could be declared final | 159 |
| Use block level rather than method level synchronization | 173 - 179 |
| Ensure that resources like this Statement object are closed after use | 187 |
| Found 'DD'-anomaly for variable 'result' (lines '187'-'189'). | 187 - 189 |
| Found 'DD'-anomaly for variable 'result' (lines '202'-'207'). | 202 - 207 |
| Local variable 'dbHome' could be declared final | 204 |
| Avoid using Literals in Conditional Statements | 205 |
| Local variable 'f' could be declared final | 206 |
| Found 'DD'-anomaly for variable 'result' (lines '218'-'221'). | 218 - 221 |
| Local variable 'userHome' could be declared final | 219 |
| Avoid using Literals in Conditional Statements | 220 |
| Assigning an Object to null is a code smell. Consider refactoring. | 236 |
| Assigning an Object to null is a code smell. Consider refactoring. | 237 |
| Violation | Line |
|---|---|
| A class which only has private constructors should be final | 40 - 227 |
| Parameter 'connector' is not assigned and could be declared final | 65 |
| Use block level rather than method level synchronization | 76 - 81 |
| Parameter 'connector' is not assigned and could be declared final | 76 |
| Avoid using Literals in Conditional Statements | 77 |
| Ensure that resources like this Statement object are closed after use | 90 |
| Local variable 'st' could be declared final | 90 |
| Parameter 'ownerId' is not assigned and could be declared final | 103 |
| Parameter 'uuid' is not assigned and could be declared final | 103 |
| Found 'DD'-anomaly for variable 'exists' (lines '105'-'106'). | 105 - 106 |
| Ensure that resources like this Statement object are closed after use | 109 |
| Local variable 'st' could be declared final | 109 |
| Parameter 'uuid' is not assigned and could be declared final | 127 |
| Found 'DD'-anomaly for variable 'result' (lines '128'-'137'). | 128 - 137 |
| Ensure that resources like this Statement object are closed after use | 131 |
| Local variable 'st' could be declared final | 131 |
| Ensure that resources like this ResultSet object are closed after use | 132 |
| Local variable 'rs' could be declared final | 132 - 133 |
| Local variable 'val' could be declared final | 135 |
| Avoid using Literals in Conditional Statements | 136 |
| Parameter 'ownerId' is not assigned and could be declared final | 156 |
| Found 'DD'-anomaly for variable 'result' (lines '157'-'166'). | 157 - 166 |
| Ensure that resources like this Statement object are closed after use | 160 |
| Local variable 'st' could be declared final | 160 |
| Ensure that resources like this ResultSet object are closed after use | 161 |
| Local variable 'rs' could be declared final | 161 - 162 |
| Local variable 'val' could be declared final | 164 |
| Avoid using Literals in Conditional Statements | 165 |
| Parameter 'ownerId' is not assigned and could be declared final | 185 |
| Ensure that resources like this Statement object are closed after use | 187 |
| Local variable 'st' could be declared final | 187 |
| Parameter 'uuid' is not assigned and could be declared final | 200 |
| Ensure that resources like this Statement object are closed after use | 202 |
| Local variable 'st' could be declared final | 202 |
| Assigning an Object to null is a code smell. Consider refactoring. | 223 |
| Assigning an Object to null is a code smell. Consider refactoring. | 224 |