Fork me on GitHub

Résultats PMD

Le document suivant contient les résultats de PMD 6.13.0.

Violations By Priority

Priority 1

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AdminOauth2Authentication.java

Rule Violation Ligne
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 173

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClient.java

Rule Violation Ligne
FieldNamingConventions The constant name '_mapper' doesn't match '[A-Z][A-Z_0-9]*' 64
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 92

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClientJson.java

Rule Violation Ligne
FieldNamingConventions The constant name '_mapper' doesn't match '[A-Z][A-Z_0-9]*' 61
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 94

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Service.java

Rule Violation Ligne
FieldNamingConventions The static field name 'ATTRIBUTE_USER_MAPPING' doesn't match '_[a-z][a-zA-Z0-9]*' 66
FieldNamingConventions The static field name 'ATTRIBUTE_USER_KEY_NAME' doesn't match '_[a-z][a-zA-Z0-9]*' 69

fr/paris/lutece/plugins/adminauthenticationoauth2/web/AdminOauth2Filter.java

Rule Violation Ligne
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 168

Priority 2

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClient.java

Rule Violation Ligne
GuardLogStatement Logger calls should be surrounded by log level guards. 165

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Service.java

Rule Violation Ligne
GuardLogStatement Logger calls should be surrounded by log level guards. 297

Priority 3

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AdminOauth2Authentication.java

Rule Violation Ligne
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 98–101
ShortVariable Avoid variables with short names like s2 231
ShortVariable Avoid variables with short names like s1 231
ShortVariable Avoid variables with short names like s 231

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AdminOauth2User.java

Rule Violation Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 76–112

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClient.java

Rule Violation Ligne
CyclomaticComplexity The method 'handleError(HttpServletRequest, HttpServletResponse, String)' has a cyclomatic complexity of 10. 116–179
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 139
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 143
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 146

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClientJson.java

Rule Violation Ligne
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the parse method if you want a default access modifier 108–115
DefaultPackage Use explicit scoping instead of the default package private level 108–115

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Service.java

Rule Violation Ligne
CyclomaticComplexity The method 'getInstance()' has a cyclomatic complexity of 10. 86–142
NonThreadSafeSingleton Singleton is not thread safe 88–139
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 113–134
ExcessiveMethodLength Avoid really long methods. 155–262
NPathComplexity The method 'processAuthentication(HttpServletRequest, Map, Token)' has an NPath complexity of 40887 155–262
CyclomaticComplexity The method 'processAuthentication(HttpServletRequest, Map, Token)' has a cyclomatic complexity of 25. 155–262

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Utils.java

Rule Violation Ligne
CommentRequired Public method and constructor comments are required 102–109
NonThreadSafeSingleton Singleton is not thread safe 104–107
CommentRequired Public method and constructor comments are required 111–118
NonThreadSafeSingleton Singleton is not thread safe 113–116
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getAuthService method if you want a default access modifier 120–127
DefaultPackage Use explicit scoping instead of the default package private level 120–127
NonThreadSafeSingleton Singleton is not thread safe 122–125

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/IOauth2AdminUserSessionService.java

Rule Violation Ligne
CommentRequired Header comments are required 36–45
CommentRequired Public method and constructor comments are required 38
CommentRequired Public method and constructor comments are required 40
CommentRequired Public method and constructor comments are required 42
CommentRequired Public method and constructor comments are required 44

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/Oauth2AdminUserSession.java

Rule Violation Ligne
CommentRequired Header comments are required 36–78
CommentRequired Public method and constructor comments are required 42–47
CommentRequired Public method and constructor comments are required 49–52
CommentRequired Public method and constructor comments are required 54–57
CommentRequired Public method and constructor comments are required 59–62
CommentRequired Public method and constructor comments are required 64–67
CommentRequired Public method and constructor comments are required 69–72
CommentRequired Public method and constructor comments are required 74–77

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/Oauth2AdminUserSessionService.java

Rule Violation Ligne
CommentRequired Header comments are required 44–117
CommentRequired Public method and constructor comments are required 52–62
NonThreadSafeSingleton Singleton is not thread safe 54–59
MissingOverride The method 'isAdminUserUpToDate(String)' is missing an @Override annotation. 64–74
CommentRequired Public method and constructor comments are required 64–74
CommentRequired Public method and constructor comments are required 76–81
MissingOverride The method 'addAdminUserSession(String, String)' is missing an @Override annotation. 76–81
MissingOverride The method 'removeAdminUserSession(String)' is missing an @Override annotation. 83–100
CommentRequired Public method and constructor comments are required 83–100
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 94–97
CommentRequired Public method and constructor comments are required 102–116
MissingOverride The method 'notifyAdminUserUpdating(String)' is missing an @Override annotation. 102–116

fr/paris/lutece/plugins/adminauthenticationoauth2/web/AdminOauth2Filter.java

Rule Violation Ligne
CyclomaticComplexity The method 'doFilter(ServletRequest, ServletResponse, FilterChain)' has a cyclomatic complexity of 22. 92–175
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 96
ConfusingTernary Avoid if (x != y) ..; else ..; 122–138
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 209
ConfusingTernary Avoid if (x != y) ..; else ..; 290–297

fr/paris/lutece/plugins/adminauthenticationoauth2/web/Oauth2AuthenticationJspBean.java

Rule Violation Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 51–92
CommentRequired Header comments are required 51–92

Priority 4

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Service.java

Rule Violation Ligne
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.adminauthenticationoauth2.business.authentication.AdminOauth2Authentication' 36
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.spring.SpringContextService' 45

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/Oauth2AdminUserSessionService.java

Rule Violation Ligne
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.adminauthenticationoauth2.service.Oauth2Utils' 36

Fichiers

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AdminOauth2Authentication.java

Rule Violation Priority Ligne
UnnecessaryConstructor Avoid unnecessary constructors - the compiler will generate these for you 3 98–101
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 173
ShortVariable Avoid variables with short names like s2 3 231
ShortVariable Avoid variables with short names like s1 3 231
ShortVariable Avoid variables with short names like s 3 231

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AdminOauth2User.java

Rule Violation Priority Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 76–112

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClient.java

Rule Violation Priority Ligne
FieldNamingConventions The constant name '_mapper' doesn't match '[A-Z][A-Z_0-9]*' 1 64
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 92
CyclomaticComplexity The method 'handleError(HttpServletRequest, HttpServletResponse, String)' has a cyclomatic complexity of 10. 3 116–179
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 139
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 143
UseStringBufferForStringAppends Prefer StringBuilder (non-synchronized) or StringBuffer (synchronized) over += for concatenating strings 3 146
GuardLogStatement Logger calls should be surrounded by log level guards. 2 165

fr/paris/lutece/plugins/adminauthenticationoauth2/business/authentication/AuthDataClientJson.java

Rule Violation Priority Ligne
FieldNamingConventions The constant name '_mapper' doesn't match '[A-Z][A-Z_0-9]*' 1 61
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 94
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the parse method if you want a default access modifier 3 108–115
DefaultPackage Use explicit scoping instead of the default package private level 3 108–115

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Service.java

Rule Violation Priority Ligne
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.adminauthenticationoauth2.business.authentication.AdminOauth2Authentication' 4 36
UnusedImports Avoid unused imports such as 'fr.paris.lutece.portal.service.spring.SpringContextService' 4 45
FieldNamingConventions The static field name 'ATTRIBUTE_USER_MAPPING' doesn't match '_[a-z][a-zA-Z0-9]*' 1 66
FieldNamingConventions The static field name 'ATTRIBUTE_USER_KEY_NAME' doesn't match '_[a-z][a-zA-Z0-9]*' 1 69
CyclomaticComplexity The method 'getInstance()' has a cyclomatic complexity of 10. 3 86–142
NonThreadSafeSingleton Singleton is not thread safe 3 88–139
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 113–134
ExcessiveMethodLength Avoid really long methods. 3 155–262
NPathComplexity The method 'processAuthentication(HttpServletRequest, Map, Token)' has an NPath complexity of 40887 3 155–262
CyclomaticComplexity The method 'processAuthentication(HttpServletRequest, Map, Token)' has a cyclomatic complexity of 25. 3 155–262
GuardLogStatement Logger calls should be surrounded by log level guards. 2 297

fr/paris/lutece/plugins/adminauthenticationoauth2/service/Oauth2Utils.java

Rule Violation Priority Ligne
CommentRequired Public method and constructor comments are required 3 102–109
NonThreadSafeSingleton Singleton is not thread safe 3 104–107
CommentRequired Public method and constructor comments are required 3 111–118
NonThreadSafeSingleton Singleton is not thread safe 3 113–116
CommentDefaultAccessModifier To avoid mistakes add a comment at the beginning of the getAuthService method if you want a default access modifier 3 120–127
DefaultPackage Use explicit scoping instead of the default package private level 3 120–127
NonThreadSafeSingleton Singleton is not thread safe 3 122–125

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/IOauth2AdminUserSessionService.java

Rule Violation Priority Ligne
CommentRequired Header comments are required 3 36–45
CommentRequired Public method and constructor comments are required 3 38
CommentRequired Public method and constructor comments are required 3 40
CommentRequired Public method and constructor comments are required 3 42
CommentRequired Public method and constructor comments are required 3 44

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/Oauth2AdminUserSession.java

Rule Violation Priority Ligne
CommentRequired Header comments are required 3 36–78
CommentRequired Public method and constructor comments are required 3 42–47
CommentRequired Public method and constructor comments are required 3 49–52
CommentRequired Public method and constructor comments are required 3 54–57
CommentRequired Public method and constructor comments are required 3 59–62
CommentRequired Public method and constructor comments are required 3 64–67
CommentRequired Public method and constructor comments are required 3 69–72
CommentRequired Public method and constructor comments are required 3 74–77

fr/paris/lutece/plugins/adminauthenticationoauth2/service/session/Oauth2AdminUserSessionService.java

Rule Violation Priority Ligne
UnusedImports Avoid unused imports such as 'fr.paris.lutece.plugins.adminauthenticationoauth2.service.Oauth2Utils' 4 36
CommentRequired Header comments are required 3 44–117
CommentRequired Public method and constructor comments are required 3 52–62
NonThreadSafeSingleton Singleton is not thread safe 3 54–59
MissingOverride The method 'isAdminUserUpToDate(String)' is missing an @Override annotation. 3 64–74
CommentRequired Public method and constructor comments are required 3 64–74
CommentRequired Public method and constructor comments are required 3 76–81
MissingOverride The method 'addAdminUserSession(String, String)' is missing an @Override annotation. 3 76–81
MissingOverride The method 'removeAdminUserSession(String)' is missing an @Override annotation. 3 83–100
CommentRequired Public method and constructor comments are required 3 83–100
AvoidDeeplyNestedIfStmts Deeply nested if..then statements are hard to read 3 94–97
CommentRequired Public method and constructor comments are required 3 102–116
MissingOverride The method 'notifyAdminUserUpdating(String)' is missing an @Override annotation. 3 102–116

fr/paris/lutece/plugins/adminauthenticationoauth2/web/AdminOauth2Filter.java

Rule Violation Priority Ligne
CyclomaticComplexity The method 'doFilter(ServletRequest, ServletResponse, FilterChain)' has a cyclomatic complexity of 22. 3 92–175
AvoidLiteralsInIfCondition Avoid using Literals in Conditional Statements 3 96
ConfusingTernary Avoid if (x != y) ..; else ..; 3 122–138
AvoidThrowingRawExceptionTypes Avoid throwing raw exception types. 1 168
UseCollectionIsEmpty Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 3 209
ConfusingTernary Avoid if (x != y) ..; else ..; 3 290–297

fr/paris/lutece/plugins/adminauthenticationoauth2/web/Oauth2AuthenticationJspBean.java

Rule Violation Priority Ligne
MissingSerialVersionUID Classes implementing Serializable should set a serialVersionUID 3 51–92
CommentRequired Header comments are required 3 51–92