Uploaded image for project: 'OpenIDM'
  1. OpenIDM
  2. OPENIDM-4799

with OrientDB repo, reading managed user with encoded quote in ID is failing with server error on policy

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Fix
    • Affects Version/s: OpenIDM 4.0.0
    • Fix Version/s: None
    • Labels:
    • Environment:
      OpenIDM version "4.0.0-SNAPSHOT" (revision: 7ba45e1) jenkins-OpenIDM - postcommit-855

      Description

      with OrientDB repo, reading managed user with encoded quote in ID is failing with server error on policy
      This problem does not occur with MySQL and postgreSQL (not tested with other repos)

      To reproduce
      1) create a user with encoded quote in ID

      curl --header "If-None-Match: *" --header "Content-Type: application/json" --header "X-OpenIDM-Password: openidm-admin" --header "X-OpenIDM-Username: openidm-admin" --data '{"userName": "rsutter", "telephoneNumber": "6669876987", "givenName": "rick", "description": "Just another John Doe or Joe Smith", "sn": "sutter", "mail": "rick@example.com", "password": "Th3Password"}' --request PUT "http://localhost:8080/openidm/managed/user/user%27with%27encoded%27quote"
      {"_id":"user'with'encoded'quote","_rev":"1","userName":"rsutter","telephoneNumber":"6669876987","givenName":"rick","description":"Just another John Doe or Joe Smith","sn":"sutter","mail":"rick@example.com","accountStatus":"active","effectiveRoles":[],"effectiveAssignments":[]}
      

      2) read this user:

      curl --header "X-OpenIDM-Password: openidm-admin" --header "X-OpenIDM-Username: openidm-admin"  --request GET "http://localhost:8080/openidm/managed/user/user%27with%27encoded%27quote"
      {
        "code": 500,
        "reason": "Internal Server Error",
        "message": "Error on parsing command at position #53: Invalid keyword 'WITH'ENCODED''\nCommand: select * from managed_user where _openidm_id = 'user'with'encoded'quote'\n-------------------------------------------------------------^"
      }
      

        Attachments

          Activity

            People

            • Assignee:
              andi andi
              Reporter:
              laurent.bristiel Laurent Bristiel [X] (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: