Also update binding versions and lock files.
Note:
- Ruby binding is not updated
- C# binding is v0.7.0. We will make it match Regorus version later.
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- Specify compatibility = linux in pyproject.toml to ensure
manylinux compatibility.
- Use abi-py310 pyo3 feature to ensure compatibility with python
3.10 and later.
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
Organize C# binding example into separate Regorus nuget package and
a test app.
The nuget package targets netstandard 2.0 and 2.1.
The test app is tested for netframework 8.0.
Implement IDisposable for Engine cleanup.
Also remove net40 example. Can be added back later if needed.
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
Removed cryptographically insecure sha1. This existed only for OPA
compatibility.
Also exclude bindings from main workspace
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
Add `or` operator to Rego languages. Available via `rego-extensions`
Cargo feature.
If the evaluated lhs value is not false, null or undefined it is returned.
Otherwise rhs is evaluated and returned.
or operator has least precedence, and is left-associative.
closes#314
Also add test to lock down example policy path.
Also Fix clippy warning by using unwrap_or_default
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- Created an example of extension policy
- Added C# binding support of .NET framework 4.0 and created a Nuget
spec for it.
- Added a pytest in python bindings to test the extension policy and the
python binding
- Restructured the example and Csharp binding directories due to above
changes.
- Added copyrights.
- Added a Windows workflow for .NET 4.0 build and test.
- Use regorus_ffi in target_link_libraries instead of regorus-ffi.
Something seems to have changed in corrosion-rs to need this.
- Workaround for cmake issue where FFI header may not be generated in time
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- c, cpp
- csharp
- ffi
- go
- Java
- Python
- WASM
`arc` feature is turned on for all bindings
Use pretty string instead of colored string.
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- Disable default features in dependencies
- Use anyhow::Error::msg to map errors. Note: anyhow will itself be removed later.
- lazy_static/spin_no_std used in no_std environments
- ensure_no_std binary is built to target thumbv7m-none-eabi to ensure that
there are no std dependencies. thumbv7m-none-eabi target has no std support.
- The opa-no-std feature enables only those Regorus features that work with no_std.
- Enable tests with no_std
- Update sizes of regorus binary in README.md
- Ensure that regorus example can be built with only std
- Ensure that regorus example can be built with no_std
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- `std` feature is enabled by default
- By default enable #![no_std] compilation
- Import std create if `std` feature is enabled or if testing
- Use core, alloc types
- Make it clear where std types are being used
- In no std, use BTreeMap in place of HashMap.
HashMap is not available in no std due to lack of a
secure random number generator
Note: The project does not yet compile without std feature being specified.
But it's really close to being able to do so.
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
The feature does not interoperate well with other serde_json features like untagged enums.
Fixes#199
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
* bindings/java: Add prefix to native methods
* bindings/java: Add javadocs and missing methods to Engine
* Setup publishing uber-JAR via GitHub workflow
* bindings/java: Update README
* bindings/java: Improve native library loading from JAR
* bindings/java: Fix usage of `working-directory`
* bindings/java: Pass required `distribution` parameter to `actions/setup-java@v4`
* bindings/java: Use Corretto distribution
This is because Microsoft doesn't provide JDK8,
see https://learn.microsoft.com/en-us/java/openjdk/download#openjdk-8.
* bindings/java: Install GCC toolchain for `aarch64-unknown-linux-gnu`
* bindings/java: Upload artifacts with different names from each step
* bindings/java: Upload built JARs to GitHub
- No need to build with coverage by default on linux platforms
- Will add coverage formally in CI later
- Rename rust.yml to pr.yml
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
* Add `time` to opa.passing. Disable WASM from rust.yml
Bindings will be tested using a separate workflow.
Also remove scripts that are no longer useful
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
* Remove alpha tag from version
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
---------
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
- units.parse, units.parse_bytes
- json.is_valid, json.marshal, json.unmarshal
- yaml.is_valid, yaml.marshal, yaml.unmarshal
- object.subset
- set_diff
* Also print number of errors due to each missing function
* Also lock down fully passing OPA suites
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>
cargo config
1. MUSL is no longer the default target. This allows building on Mac and Windows.
2. On Linux, code coverage compiler options are supplied by default.
pre-commit, pre-push
- Coverage is turned on only on Linux
- clippy is run on all platforms
github
- MUSL build is tested to ensure that stand alone executables can be created
Signed-off-by: Anand Krishnamoorthi <anakrish@microsoft.com>