{"id":20741107,"url":"https://github.com/robtimus/obfuscation-jackson-databind","last_synced_at":"2026-03-12T04:32:13.891Z","repository":{"id":53938101,"uuid":"262098756","full_name":"robtimus/obfuscation-jackson-databind","owner":"robtimus","description":"Provides support for serializing and deserializing obfuscated values using Jackson","archived":false,"fork":false,"pushed_at":"2026-02-03T18:39:48.000Z","size":650,"stargazers_count":7,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-02-04T07:54:21.108Z","etag":null,"topics":["jackson","jackson-databind","java","json","obfuscation"],"latest_commit_sha":null,"homepage":"https://robtimus.github.io/obfuscation-jackson-databind/","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/robtimus.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-05-07T16:13:01.000Z","updated_at":"2026-02-03T18:39:52.000Z","dependencies_parsed_at":"2023-02-15T17:46:18.168Z","dependency_job_id":"9754ebe7-4e9f-42e4-add1-bb41dc0beac7","html_url":"https://github.com/robtimus/obfuscation-jackson-databind","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/robtimus/obfuscation-jackson-databind","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robtimus%2Fobfuscation-jackson-databind","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robtimus%2Fobfuscation-jackson-databind/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robtimus%2Fobfuscation-jackson-databind/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robtimus%2Fobfuscation-jackson-databind/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/robtimus","download_url":"https://codeload.github.com/robtimus/obfuscation-jackson-databind/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/robtimus%2Fobfuscation-jackson-databind/sbom","scorecard":{"id":270715,"data":{"date":"2025-08-11","repo":{"name":"github.com/robtimus/obfuscation-jackson-databind","commit":"a37d78667bf3ad1ad6a205a7305f15681e1ccd17"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.2,"checks":[{"name":"Maintained","score":1,"reason":"2 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/build.yml:1","Warn: no topLevel permission defined: .github/workflows/dependency-review.yml:1","Warn: topLevel 'contents' permission set to 'write': .github/workflows/release-site.yml:22","Warn: no topLevel permission defined: .github/workflows/sonarcloud.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:34: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:45: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:47: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:60: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:62: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:73: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:75: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/build.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/dependency-review.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/dependency-review.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/dependency-review.yml:26: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/dependency-review.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release-site.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/release-site.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/release-site.yml:30: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/release-site.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/release-site.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/release-site.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/sonarcloud.yml:31: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/sonarcloud.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/sonarcloud.yml:35: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/sonarcloud.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/sonarcloud.yml:58: update your workflow using https://app.stepsecurity.io/secureworkflow/robtimus/obfuscation-jackson-databind/sonarcloud.yml/master?enable=pin","Info:   0 out of  14 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE.txt:0","Info: FSF or OSI recognized license: Apache License 2.0: LICENSE.txt:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":0,"reason":"Project has not signed or included provenance with any releases.","details":["Warn: release artifact 1.2.1 not signed: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/167480623","Warn: release artifact 1.2 not signed: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/85038742","Warn: release artifact 1.1.6 not signed: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/80628859","Warn: release artifact 1.1.5 not signed: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/79528465","Warn: release artifact 1.1.4 not signed: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/73809223","Warn: release artifact 1.2.1 does not have provenance: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/167480623","Warn: release artifact 1.2 does not have provenance: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/85038742","Warn: release artifact 1.1.6 does not have provenance: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/80628859","Warn: release artifact 1.1.5 does not have provenance: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/79528465","Warn: release artifact 1.1.4 does not have provenance: https://api.github.com/repos/robtimus/obfuscation-jackson-databind/releases/73809223"],"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-17T13:16:44.852Z","repository_id":53938101,"created_at":"2025-08-17T13:16:44.853Z","updated_at":"2025-08-17T13:16:44.853Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30415516,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-12T04:25:42.844Z","status":"ssl_error","status_checked_at":"2026-03-12T04:25:34.624Z","response_time":114,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["jackson","jackson-databind","java","json","obfuscation"],"created_at":"2024-11-17T06:33:51.915Z","updated_at":"2026-03-12T04:32:13.873Z","avatar_url":"https://github.com/robtimus.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# obfuscation-jackson-databind\n[![Maven Central](https://img.shields.io/maven-central/v/com.github.robtimus/obfuscation-jackson-databind)](https://search.maven.org/artifact/com.github.robtimus/obfuscation-jackson-databind)\n[![Build Status](https://github.com/robtimus/obfuscation-jackson-databind/actions/workflows/build.yml/badge.svg)](https://github.com/robtimus/obfuscation-jackson-databind/actions/workflows/build.yml)\n[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=com.github.robtimus%3Aobfuscation-jackson-databind\u0026metric=alert_status)](https://sonarcloud.io/summary/overall?id=com.github.robtimus%3Aobfuscation-jackson-databind)\n[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=com.github.robtimus%3Aobfuscation-jackson-databind\u0026metric=coverage)](https://sonarcloud.io/summary/overall?id=com.github.robtimus%3Aobfuscation-jackson-databind)\n[![Known Vulnerabilities](https://snyk.io/test/github/robtimus/obfuscation-jackson-databind/badge.svg)](https://snyk.io/test/github/robtimus/obfuscation-jackson-databind)\n\nProvides support for serializing and deserializing obfuscated values using Jackson. All you need to do is register a module:\n\n```java\nModule module = ObfuscationModule.defaultModule();\nmapper.registerModule(module);\n```\n\nThis will automatically allow all instances of [Obfuscated](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscated.html) to be serialized and deserialized, without the need for any custom serializer or deserializer. In fact, any annotation used (apart from the ones below) will be used for the `Obfuscated` object's *value*, not the `Obfuscated` object itself. That means that you can provide custom serialization and/or deserialization for the value the way you're used to, without needing to wrap it inside a new serializer or deserializer.\n\n## Annotation-based obfuscation\n\nWith the annotations from [obfuscation-annotations](https://robtimus.github.io/obfuscation-annotations), you can control how values are obfuscated during deserialization. This is supported for the following types:\n\n### Obfuscated\n\n* Use an annotation like `@ObfuscateFixedLength(3)` or `@ObfuscateAll` to specify a custom obfuscator to use for the `Obfuscated` property during deserialization.\n* Use `@RepresentedBy` to provide a custom character representation.\n\n### List, Set, Collection and Map\n\n* Use an annotation like `@ObfuscateFixedLength(3)` or `@ObfuscateAll` to apply obfuscation to a `List`, `Set`, `Collection` or `Map` property during deserialization. This is done using [Obfuscator.obfuscateList](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscator.html#obfuscateList-java.util.List-java.util.function.Function-), [Obfuscator.obfuscateSet](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscator.html#obfuscateSet-java.util.Set-java.util.function.Function-), [Obfuscator.obfuscateCollection](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscator.html#obfuscateCollection-java.util.Collection-java.util.function.Function-) and [Obfuscator.obfuscateMap](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscator.html#obfuscateMap-java.util.Map-java.util.function.Function-) respectively.\n* Use `@RepresentedBy` to provide a custom character representation for the generic element/value type. This annotation will be ignored if no obfuscation is applied to the property.\n\n## Default obfuscators\n\nBy default, deserialized `Obfuscated` properties that are not annotated with any of the annotations from [obfuscation-annotations](https://robtimus.github.io/obfuscation-annotations) will use [Obfuscator.fixedLength(3)](https://robtimus.github.io/obfuscation-core/apidocs/com/github/robtimus/obfuscation/Obfuscator.html#fixedLength-int-). This can be overridden by using a builder to create the module. With this builder, it's possible to define default obfuscators per type, or a global default obfuscator:\n\n```java\nModule module = ObfuscationModule.builder()\n        .withDefaultObfuscator(String.class, Obfuscator.portion().keepAtStart(2).build())\n        .withDefaultObfuscator(Obfuscator.fixedValue(\"\u003cobfuscated\u003e\"))\n        .build();\nmapper.registerModule(module);\n```\n\nA type-specific obfuscator will be used if the generic value type of the `Obfuscated` property matches. This takes into account super classes and implemented interfaces. If there is no match, the global default obfuscator is used.\n\nA type-specific obfuscator will be used not just for `Obfuscated` properties, but also any `List`, `Set`, `Collection` or `Map` property with a matching generic element/value type. This can be disabled by calling `requireObfuscatorAnnotation(true)` on the builder. The global default obfuscator will not cause any `List`, `Set`, `Collection` or `Map` to be obfuscated.\n\n### Obfuscator lookup order\n\nThe following order is used to look up obfuscators for properties:\n\n1. The obfuscator defined in the property's own annotations.\n2. The default obfuscator defined for the property's generic element/value type when creating the module.\n3. The obfuscator defined in the class annotations of the property's generic element/value type.\n4. The global default obfuscator.\n\n## Default character representation providers\n\nLike default obfuscators, it's also possible to define default character representation providers per type:\n\n```java\nModule module = ObfuscationModule.builder()\n        .withDefaultCharacterRepresentation(Date.class, d -\u003e formatDate(d))\n        .build();\nmapper.registerModule(module);\n```\n\nThe matching will be the same as for default obfuscators.\n\nLike type-specific obfuscators, a type-specific character representation provider will also be used for any `List`, `Set`, `Collection` or `Map` property with a matching generic element/value type that is obfuscated during deserialization.\n\n### Character representation provider lookup order\n\nThe following order is used to look up character representation providers for properties:\n\n1. The character representation provider defined in the property's own annotations.\n2. The default character representation provider defined for the property's generic element/value type when creating the module.\n3. The character representation provider defined in the class annotations of the  property's generic element/value type.\n4. The result of calling [CharacterRepresentationProvider.getDefaultInstance](https://robtimus.github.io/obfuscation-annotations/apidocs/com/github/robtimus/obfuscation/annotation/CharacterRepresentationProvider.html#getDefaultInstance-java.lang.Class-) for the property's generic type. This has special support for arrays, so it's not necessary to use `@RepresentedBy` on any array property just to prevent obfuscating values like `[I@490d6c15` instead of `[1, 2, 3]`.\n\n## Examples\n\n### Obfuscate with a fixed length\n\n```java\n@ObfuscateFixedLength(3)\nprivate Obfuscated\u003cString\u003e stringValue;\n```\n\n### Obfuscate with the default obfuscator, but provide custom serialization of the obfuscated value\n\n```java\n@JsonFormat(pattern = \"yyyy-MM-dd'T'HH:mm:ss.SSSZ\")\n@JsonSerialize(using = DateSerializer.class)\n@JsonDeserialize(using = DateDeserializer.class)\n@RepresentedBy(DateFormat.class)\nprivate Obfuscated\u003cDate\u003e dateValue;\n```\n\nAssume that DateFormat formats Date objects as `yyyy-MM-dd`, then this will obfuscate values like `1970-01-01` and not `Thu Jan 01 00:00:00 GMT 1970`.\n\nNote that the format, serializer and deserializer target `Date`, not `Obfuscated`.\n\n### Obfuscate a List\n\n```java\n@ObfuscateFixedLength(3)\nprivate List\u003cString\u003e obfuscatedList;\n```\n\nNote that the annotation is needed; the following is not obfuscated (unless there is a default obfuscator for `String` or one of its super types):\n\n```java\nprivate List\u003cString\u003e regularList;\n```\n\n### Obfuscate a List using a custom character representation\n\n```java\n@ObfuscatePortion(keepAtStart = 8)\n@RepresentedBy(DateFormat.class)\nprivate List\u003cDate\u003e obfuscatedList;\n```\n\nAssume that DateFormat formats Date objects as `yyyy-MM-dd`, then this will obfuscate the days, leaving values like `1970-01-**`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobtimus%2Fobfuscation-jackson-databind","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frobtimus%2Fobfuscation-jackson-databind","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frobtimus%2Fobfuscation-jackson-databind/lists"}