Skip to content

etrapani/cedar-java

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cedar-java

This repository contains the source code for a Java package CedarJava that supports using the Cedar policy language. It also contains source code for a Rust crate CedarJavaFFI that enables calling Cedar library functions (written in Rust) from Java.

Getting Started

You can find detailed build instructions and more information in the subfolders CedarJavaFFI, CedarJava.

For typical use, you'll want something like:

cd CedarJavaFFI && cargo build
cd ../CedarJava
export CEDAR_INTEGRATION_TESTS_ROOT=/tmp #(assuming you don't want to run them)
export CEDAR_JAVA_FFI_LIB=path_to_CedarJavaFFI/target/debug/libcedar_java_ffi.so #(or wherever you built CedarJavaFFI)
gradle test

Notes

You need JDK 17 or later to run the Java code.

Cedar is primarily developed in Rust (in the cedar repository). As such, CedarJava typically lags behind the newest Cedar features. Notably, as of this writing, CedarJava does not expose APIs for partial evaluation.

The main branch of this repository is kept up-to-date with the development version of the Rust code (available in the main branch of cedar). Unless you plan to build the Rust code locally, please use the latest release/x.x.x branch instead.

Security

See CONTRIBUTING for more information.

License

This project is licensed under the Apache-2.0 License.

About

Java bindings for the Cedar language

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 85.4%
  • Rust 13.9%
  • Shell 0.7%