Closed (fixed)
Project:
Monitoring
Version:
8.x-1.x-dev
Component:
Sensors
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
7 Dec 2014 at 10:52 UTC
Updated:
23 Dec 2014 at 21:24 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
miro_dietikerComment #2
miro_dietikerComment #3
miro_dietikerLowering priority as this is not a low hanging fruit... With high probability, the captcha module needs improvements in reporting / logs / accessibility of statistics.
Comment #4
berdirActually seems to be not that hard :)
database aggregator sensor on captcha_sessions table, condition 1 on status = 0, condition 2 on attempts > 0. Currently can not be done in the UI, but you can create it except condition 2 and then add that in yml.
Comment #5
Anushka-mp commentedDefault sensor created for counting the no. of users who has failed attempts. The sensor to count the total number of attempts from all users needs to be created. submitting this for a review.
Comment #6
Anushka-mp commentedTest dependancy added.
Comment #7
Anushka-mp commentedWhat about the time interval? failed attempts in past 24 hours? currently there is no time interval added when calculating the result.
Comment #10
berdirMove this to default configuration, that's what we have the config/install/$module structure for.
We only need code for things that are more complex (like dependency on two modules).
It is also missing the second condition on attempts > 0.
There is a test captcha plugin that expects a fixed answer. Have a look at their tests. Either that or look up the correct answer in the database after you request the page.
We need to produce data for all possible combinations:
- Just visit the form, this should create a session with attempts = 0
- With a different session/form (you need to check if simply reloading the form is enough to create two rows), submit the form with the wrong answer
- Yet another session, submit successfully the first time
- Yet another session, submit first wrong then correct answer.
Then you should have 4 entries in captcha_sessions (check that with an asserEqual(db_query()->fetchField(), 4). Then run the sensor and it should only report 1.
Comment #12
miro_dietikerTest dependency pushed. Let's wait a day and then retest. Should pass all green then.
Comment #13
miro_dietikerOh, cross post with @sgr review. Needs work then.
Comment #14
Anushka-mp commentedDefault configuration created for the sensor and the condition amount > 0 added.
Tests are corrected as mentioned in Berdir's comment.
this would fail, Let's wait for the test dependency and retest.
Comment #16
Anushka-mp commentedInteresting, UI test failure. I'll look in to that. :/
Comment #17
Anushka-mp commentedUI tests are broken now, created an Issue #2389969: Fix broken UI test due to the core change
Comment #19
miro_dietikerOK. Committed this. UI fails are unrelated.