Wrong SAML attributes encoding issued by IDP
When using LL::NG as IDP and simpleSAMLphp as SP, with LDAP backend as authentication backend, sent SAML attributes a wrong encoded.
Don't know if the problem is in the internal encoding of values in LL::NG code/sessions, or when we build SAML attributes.
A quick fix is to comment the "encode" call in sub createAttributeValue in _SAML.pm :
## @method Lasso::Saml2AttributeValue createAttributeValue(string value)
# Create a new SAML attribute value
# @param value Value to store
# @return SAML attribute value
sub createAttributeValue {
my ( $self, $value ) = @_;
my $saml2value;
# Value is required
return unless defined $value;
# Decode UTF-8
#$value = decode( "utf8", $value );
{code}
But in OpenIDConnect we also force the decoding of attributes, see sub buildUserInfoResponse:
{code:perl}
my $session_value = $apacheSession->data->{$session_key};
utf8::decode($session_value);
So we must find a standard encoding behavior.