Problem/Motivation

While on this path admin/config/people/saml_sp/setup I ran into this warning:

Warning: Declaration of saml_sp_Auth::login($returnTo = NULL, array $parameters = Array, $forceAuthn = false, $isPassive = false, $stay = false, $setNameIdPolicy = true) should be compatible with OneLogin\Saml2\Auth::login($returnTo = NULL, array $parameters = Array, $forceAuthn = false, $isPassive = false, $stay = false, $setNameIdPolicy = true, $nameIdValueReq = NULL)

Proposed resolution

Add this additional parameter
, $nameIdValueReq = NULL

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

CommentFileSizeAuthor
#2 3156832-2.patch4.95 KBjoelpittet

Comments

joelpittet created an issue. See original summary.

joelpittet’s picture

Status: Active » Needs review
StatusFileSize
new4.95 KB

Turned into a bigger patch because _lastRequestID and _lastRequest are private now and can't be written to directly.

I removed the saml_sp_AuthnRequest class because it seemed redundant and called the parent::login() and got the variables filled in different ways.

jrglasgow’s picture

Status: Needs review » Needs work

The saml_sp_AuthnRequest class is there specifically for the debugging options and I won't commit the patch with it out of the chain unless you have a better option for debugging the AuthN request. Specifically I want a way to output the complete XML for the request so it can both be read by a developer working on debugging and easily put into a validator like this one https://www.samltool.com/validate_authn_req.php

joelpittet’s picture

Status: Needs work » Needs review

@jrglasgow Thanks for the quick response.

I moved the debugging that saml_sp_AuthnRequest , sorry I should have mentioned it was a end of the day rush to post the code, so didn't lose it, just moved it up. The idea is that it would save you from maintaining one less class that apparently has interface changes every so often:

+++ b/includes/saml_sp.Auth.inc
@@ -69,9 +45,17 @@ class saml_sp_Auth extends Auth {
+    if (variable_get('saml_sp__debug', FALSE)) {
+      watchdog('saml_sp', 'samlp:AuthnRequest =><br/><pre>@request</pre>', array('@request' => $this->getLastRequestXML()), WATCHDOG_DEBUG);
+      if (function_exists('dpm')) {
+        dpm($this->getXML(), 'samlp:AuthnRequest');
+      }
+    }

+++ /dev/null
@@ -1,22 +0,0 @@
-    if (variable_get('saml_sp__debug', FALSE)) {
-      watchdog('saml_sp', 'samlp:AuthnRequest =><br/><pre>@request</pre>', array('@request' => $this->getXML()), WATCHDOG_DEBUG);
-      if (function_exists('dpm')) {
-        dpm($this->getXML(), 'samlp:AuthnRequest');
-      }
-    }
joelpittet’s picture

Thoughts? @jrglasgow And could 3.x get a dev branch?

jrglasgow’s picture

@joelpettit
I have added you as a maintainer to make it easier for you to get your changes in.

joelpittet’s picture

Thanks @jrglasgow!

joelpittet’s picture

Status: Needs review » Fixed

  • joelpittet committed dfba0b0 on 7.x-3.x
    Issue #3156832 by joelpittet, jrglasgow: Missing parameter $...

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.