Uploaded image for project: 'Ranger'
  1. Ranger
  2. RANGER-733

Implement best coding practices to resolve issues found during code scan

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.5.0, 0.6.0
    • 0.5.1, 0.6.0
    • None
    • None

    Description

      Fix reported issues in below classes:

      File: org/apache/ranger/json/JsonDateSerializer.java
      Call to method of static java.text.DateFormat in org.apache.ranger.json.JsonDateSerializer.serialize(Date, JsonGenerator, SerializerProvider)

      Method: org.apache.ranger.biz.XUserMgr.updateXModuleDefPermission(VXModuleDef)
      Make sure that getIsAllowed() is done without AUTOBOXING

      File: org/apache/ranger/service/XAccessAuditService.java
      Field XAccessAuditService.searchFields masks field in superclass org.apache.ranger.service.AbstractBaseResourceService

      Field XAccessAuditService.sortFields masks field in superclass org.apache.ranger.service.AbstractBaseResourceService

      File: org/apache/ranger/service/XPolicyService.java
      Line#: 239
      if (assetType == 0 || assetType == AppConstants.ASSET_UNKNOWN) - are same condition!

      File: org/apache/ranger/view/VXGroupPermission.java
      Field VXGroupPermission.id masks field in superclass org.apache.ranger.view.VXDataObject

      File: org/apache/ranger/view/VXModuleDef.java
      Field VXModuleDef.id masks field in superclass org.apache.ranger.view.VXDataObject

      File: org/apache/ranger/view/VXUserPermission.java
      Field VXUserPermission.id masks field in superclass org.apache.ranger.view.VXDataObject

      Fix logging in below classes:

      ./unixauthclient/src/main/java/org/apache/ranger/authentication/unix/jaas/RemoteUnixLoginModule.java
      ./lookup-client/src/main/java/org/apache/ranger/storm/client/StormClient.java

      Attachments

        Issue Links

          Activity

            People

              gautamborad Gautam Borad
              vel Velmurugan Periasamy
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: