Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Logging AD errors in PostgreSQL ends with error #7

Open
karelmaxa opened this issue Jun 4, 2018 · 0 comments
Open

Logging AD errors in PostgreSQL ends with error #7

karelmaxa opened this issue Jun 4, 2018 · 0 comments

Comments

@karelmaxa
Copy link
Member

When AD returns an error (e.g. permission denied) somewhere in between AD, LDAP Connector and OpenIDM an invalid String gets created. When logging the error to audit tables with PostgreSQL the following exception is being thrown:

Apr 21, 2016 4:23:10 PM org.forgerock.openidm.servlet.internal.ServletConnectionFactory$4 handleException
WARNING: Resource exception: 500 Internal Server Error: "Creating object failed (0-22021)ERROR: invalid byte sequence for encoding "UTF8": 0x00" 
org.forgerock.json.resource.InternalServerErrorException: Creating object failed (0-22021)ERROR: invalid byte sequence for encoding "UTF8": 0x00
        at org.forgerock.openidm.repo.jdbc.impl.JDBCRepoService.create(JDBCRepoService.java:354)
        at org.forgerock.openidm.repo.jdbc.impl.JDBCRepoService.handleCreate(JDBCRepoService.java:290)
        at org.forgerock.json.resource.Router.handleCreate(Router.java:255)
 ...
Caused by: org.postgresql.util.PSQLException: ERROR: invalid byte sequence for encoding "UTF8": 0x00
        at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2161)
        at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1890)
        at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:559)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:417)
        at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:363)
        at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source)

I guess that issue could be solved in forgerock-audit module. Official bugster issue: https://bugster.forgerock.org/jira/browse/OPENICF-581

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant