You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If in doubt include the whole thing; often exceptions get wrapped in other exceptions and the exception right near the bottom explains the actual error, not the first few lines at the top.
Your code and/or AuthzForce-specific configuration file(s)
final Optional<BooleanValue> constant = evaluableExpression.getValue(); if (constant.isPresent()) { if (constant.get().getUnderlyingValue()) { // constant TRUE LOGGER.warn("Condition's expression is equivalent to constant True -> optimization: replacing with constant True condition"); return TRUE_CONDITION; } // constant False -> unacceptable throw INVALID_CONSTANT_FALSE_EXPRESSION_EXCEPTION; }
What is motivation behind this exception throwing, especially is it driven by the specification?
What would happen if that exception throwing line would not be present? Would Policy be considered "valid" and evaluates normally - with condition evaluating into false
The text was updated successfully, but these errors were encountered:
Software version (AuthzForce Core)
(current master)
Platform JRE
Platform OS
Error stack trace or logs (if any)
If in doubt include the whole thing; often exceptions get wrapped in other exceptions and the exception right near the bottom explains the actual error, not the first few lines at the top.
Your code and/or AuthzForce-specific configuration file(s)
https://github.com/authzforce/core/blob/develop/pdp-engine/src/main/java/org/ow2/authzforce/core/pdp/impl/rule/ConditionEvaluators.java
The following part of code puzzles me:
final Optional<BooleanValue> constant = evaluableExpression.getValue(); if (constant.isPresent()) { if (constant.get().getUnderlyingValue()) { // constant TRUE LOGGER.warn("Condition's expression is equivalent to constant True -> optimization: replacing with constant True condition"); return TRUE_CONDITION; } // constant False -> unacceptable throw INVALID_CONSTANT_FALSE_EXPRESSION_EXCEPTION; }
What is motivation behind this exception throwing, especially is it driven by the specification?
What would happen if that exception throwing line would not be present? Would Policy be considered "valid" and evaluates normally - with condition evaluating into false
The text was updated successfully, but these errors were encountered: