After upgrading to Mollom 7.x-2.0, running update.php, cron and clearing all caches, I still get this message, "The configured Mollom API keys are invalid." I have checked, and everything is the same on my account with Mollom, and public and private keys are entered correctly on my site. After reading forum posts (which are old) I tried disabling Views and Mollom, deleting and re-installing Mollom 7.x-2.0 and enabling (with Views still disabled), and still no solution.

Comments

couturier’s picture

Component: Code » User interface
Status: Fixed » Active

To follow up, this is the error message I'm getting:

(Update: deleted this when issue was resolved)

sun’s picture

Component: User interface » Code
Status: Active » Postponed (maintainer needs more info)

I just tried your API keys on a testing site myself and they were validated successfully.

Are you sure that your site/server is able to make outbound HTTP requests to rest.mollom.com? There might be a firewall or proxy in between that blocks the requests?

couturier’s picture

Status: Postponed (maintainer needs more info) » Fixed

The Mollom keys showed validation after several days with no further action required. I did email my hosting provider to ask about any firewall issues but did not receive a reply. They are Drupal-specialized hosts that contribute to Drupal core and run many sites with Mollom, so I sort of doubt that would have been the problem. In the meantime, I gained new appreciation for all that Mollom does. I had to temporarily shut down several portions of my site, due to a flood of spam, until Mollom started working again. Mollom's filtering power is great! Thanks for looking at this, sun. Just for the record, here are further comments that I received from Mollom staff:

Mar 27 08:25 pm (CEST):
I don't see any statistics from your site since the 24th; I'll raise this issue and point out the d.o. node number to the backend engineers.

Mar 27 10:18 pm (CEST):
This seems to be an system or environment issue - let's continue to discuss it on http://drupal.org/node/1497404

jonloh’s picture

I'm still having this weird Error 401, and it has been quite a few weeks already that my site is having this problem.

We are hosting sites for our clients which got no problem with Mollom, just our main site :(

MESSAGE	Invalid API keys.
Error 401: Invalid authentication.

Request: POST http://rest.mollom.com/v1/site/638138e2b39455a659932ca5360173df
  platformName = 'Drupal'
  platformVersion = '7.12'
  clientName = 'Mollom'
  clientVersion = '7.x-2.0'
Request headers:
  Accept = 'application/xml, application/json;q=0.8, */*;q=0.5'
  Content-Type = 'application/x-www-form-urlencoded'
  Authorization = 'OAuth oauth_consumer_key="638138e2b39455a659932ca5360173df", oauth_version="1.0", oauth_nonce="fc36dee08fae814b25a50abdae97b6fd", oauth_timestamp="1334019810", oauth_signature_method="HMAC-SHA1", oauth_signature="4%2BgCZZiUBf73DpNayWh25jpCf8I%3D"'
Invalid API keys.

SEVERITY	error
couturier’s picture

You might want to use the contact form directly on the Mollom website. Refer to the URL of this issue on Drupal.org so that tech support can see the details of your error and help you. You can also change the status of this issue to "active" if you like.

couturier’s picture

Status: Fixed » Active

Okay, as of this morning just after I logged in, the Mollom API keys switched over to showing invalid again. That's two of us--jonloh and myself--who are actively facing this issue, so I'm switching the status back to active. I wonder what's causing this?

My error:

Friday, April 13, 2012 - 09:53
[Details removed once issue was resolved] 
Invalid API keys.
Junni’s picture

Component: User interface » Code

Same issue here!

Invalid API keys.
Error 401: Invalid authentication.

Request: POST http://rest.mollom.com/v1/site/c2e42b80c1ef7caa869c6bbea9abf44a
  platformName = 'Drupal'
  platformVersion = '7.10'
  clientName = 'Mollom'
  clientVersion = '7.x-2.0'
Request headers:
  Accept = 'application/xml, application/json;q=0.8, */*;q=0.5'
  Content-Type = 'application/x-www-form-urlencoded'
  Authorization = 'OAuth oauth_consumer_key="c2e42b80c1ef7caa869c6bbea9abf44a", oauth_version="1.0", oauth_nonce="3ce5d72ee8b67176b8af44e1981834cb", oauth_timestamp="1334577687", oauth_signature_method="HMAC-SHA1", oauth_signature="JtQDUgoWUrkPV%2Buvg1hsIxDZV3c%3D"'
Invalid API keys.
couturier’s picture

Status: Active » Fixed

As of this morning, my Mollom keys are showing valid again. So, the first time this happened it took 5 days to clear up, and now the second time it has taken 6 days. Everything seems to have resolved on its own without intervention from either my host server or Mollom engineers. The problems started when I upgraded to version 7.x-2.0, so I'm wondering if it has something to do with the upgrade. Anyway, I am moving this issue back to fixed again.

sun’s picture

Status: Active » Fixed
jonloh’s picture

Reported to Mollom and basically sun got back to me regarding this issue, and basically my issue was because the server ran out of sync with the world-wide clock.

To settle this, I've to basically run the ntpdate command (For CentOS) and the keys resolve fine and Mollom is running perfectly now. If you do not have SSH access, request your hosting to look into this then.

Thanks sun! :)

couturier’s picture

Yes, that would make sense according to the issue sun cited which says, "If the Mollom service happens to be down and the Drupal module's client/key validation happens to be triggered during that time-frame, a bogus result is stored and sticks." My invalid key status was being triggered when I was logged into my site doing things that affected Mollom. I hope the patch will be good going forward for 7.x-2.0. Thanks for your help, sun.

Anonymous’s picture

I'm getting this error with Invalid API Keys (I replaced the key value with "[obscured by me]" text below, but it did contain the key from mollom):

Invalid API keys.

Error 900: Network error.
Request: POST http://rest.mollom.com/v1/site/[obscured by me]

  platformName = 'Drupal'
  platformVersion = '7.12'
  clientName = 'Mollom'
  clientVersion = '7.x-2.0'

Request headers:

  Accept = 'application/xml, application/json;q=0.8, */*;q=0.5'
  Content-Type = 'application/x-www-form-urlencoded'
  Authorization = 'OAuth oauth_consumer_key="[obscured by me]", oauth_version="1.0", oauth_nonce="ac6fe2eb3e7f64b4bbbd92ad0725da4a", oauth_timestamp="1335355614", oauth_signature_method="HMAC-SHA1", oauth_signature="Mnm1gteh4K4ix7VfJ8Su136zycA%3D"'

Response: -111 Connection refused

Error 900: Network error.
Request: POST http://rest.mollom.com/v1/site/[obscured by me]
  platformName = 'Drupal'
  platformVersion = '7.12'
  clientName = 'Mollom'
  clientVersion = '7.x-2.0'

Request headers:

  Accept = 'application/xml, application/json;q=0.8, */*;q=0.5'
  Content-Type = 'application/x-www-form-urlencoded'
  Authorization = 'OAuth oauth_consumer_key="[obscured by me]", oauth_version="1.0", oauth_nonce="dec46ddb390e8b84366dc6fbcf6114dc", oauth_timestamp="1335355616", oauth_signature_method="HMAC-SHA1", oauth_signature="9LhHQhZs39t6NQuvj3qUCzzR5LE%3D"'

Response: -111 Connection refused

Invalid API keys.

There's also the message The Mollom servers could not be contacted. Please make sure that your web server can make outgoing HTTP requests. on the settings page. Does all this mean that I need to speak to my hosting provider or is this smth else?

sun’s picture

Error 900: Network error.
Response: -111 Connection refused

seems pretty clear to me (and different to the previous cases) - your client does not seem to be able to communicate with mollom.com, which points to a firewall that blocks outgoing requests. So yes, talk to your hosting provider.

Status: Fixed » Closed (fixed)

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

cmejo’s picture

I can confirm #10 worked for me as well.

marthinal’s picture

Fixed after executed "ntpd -q"

Thanks!

Elijah Lynn’s picture

Just an FYI, this is happening to me only when I select testing mode. If I had previously added keys and also hit testing mode it deletes the keys I had.