Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1199246 - unable to update openscap policy due to broken schedule feature
unable to update openscap policy due to broken schedule feature
Status: CLOSED ERRATA
Product: Red Hat Satellite 6
Classification: Red Hat
Component: WebUI (Show other bugs)
6.1.0
Unspecified Unspecified
high Severity high (vote)
: Beta
: Unused
Assigned To: Shlomi Zadok
Kedar Bidarkar
: Triaged
Depends On:
Blocks: 1047797
  Show dependency treegraph
 
Reported: 2015-03-05 12:54 EST by Kedar Bidarkar
Modified: 2017-02-23 15:22 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-08-12 01:29:01 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1592 normal SHIPPED_LIVE Important: Red Hat Satellite 6.1.1 on RHEL 6 2015-08-12 05:04:35 EDT

  None (edit)
Description Kedar Bidarkar 2015-03-05 12:54:52 EST
Description of problem:
unable to update openscap policy due to broken scheduling feature.

a) I  may have to submit oscap policy  thrice to succeed. Also I feel the schedule section can be improved, currently it's not intuitive to select the options.

b) updating oscap policy with the same custom value should be possible.
when the "period" is custom, the below values are irrelevant and should not be prompted to the user to be filled in.

1) "weekday"=>"sunday",
2) "day_of_month"=>"12",


c) The possible errors are as below.

2015-03-05 23:06:43 [I] Processing by ScaptimonyPoliciesController#update as HTML
2015-03-05 23:06:43 [I]   Parameters: {"utf8"=>"✓", "authenticity_token"=>"SiRic7p2ZM4sH0202fxc03z7I4+VYkW/p0RsXBnt6I4=", "policy"=>{"name"=>"oscap_policy3", "description"=>"", "scap_content_id"=>"1", "scap_content_profile_id"=>"9", "period"=>"custom", "weekday"=>"", "day_of_month"=>"", "cron_line"=>"0 */1 * * *", "location_ids"=>["2", ""], "organization_ids"=>["1", ""], "hostgroup_ids"=>["", "3"]}, "commit"=>"Submit", "id"=>"4"}
2015-03-05 23:06:43 [I] Failed to save: Weekday is not included in the list, Day of month is not a number

2015-03-05 23:08:47 [I]   Parameters: {"utf8"=>"✓", "authenticity_token"=>"SiRic7p2ZM4sH0202fxc03z7I4+VYkW/p0RsXBnt6I4=", "policy"=>{"name"=>"oscap_policy3", "description"=>"", "scap_content_id"=>"1", "scap_content_profile_id"=>"9", "period"=>"weekly", "weekday"=>"sunday", "day_of_month"=>"", "cron_line"=>"0 */1 * * *", "location_ids"=>["2", ""], "organization_ids"=>["1", ""], "hostgroup_ids"=>["", "3"]}, "commit"=>"Submit", "id"=>"4"}
2015-03-05 23:08:47 [I] Failed to save: Day of month is not a number

*) we could see below some NULL values.

2015-03-05 23:23:52 [I] Processing by ScaptimonyPoliciesController#create as HTML
2015-03-05 23:23:52 [I]   Parameters: {"utf8"=>"✓", "authenticity_token"=>"SiRic7p2ZM4sH0202fxc03z7I4+VYkW/p0RsXBnt6I4=", "policy"=>{"current_step"=>"Locations", "name"=>"oscap_policy3u", "description"=>"", "scap_content_id"=>"1", "scap_content_profile_id"=>"3", "period"=>"weekly", "weekday"=>"sunday", "day_of_month"=>"", "cron_line"=>"", "location_ids"=>[""], "organization_ids"=>["", "1"], "hostgroup_ids"=>[""]}, "commit"=>"Next"}



Version-Release number of selected component (if applicable):
sat6.1 beta snap5

How reproducible:
when try to update using the edit link.

Steps to Reproduce:
1. create a oscap policy
2. now try updating it with some values
3. click on submit button.

Actual results:
unable to save due to above mentioned issue.


Expected results:
should be able to update oscap policy.

Additional info:
Comment 1 Kedar Bidarkar 2015-03-05 13:03:54 EST
Also it feels like currently creating a cron_line is broken even during creation of policy.
Comment 3 Kedar Bidarkar 2015-03-05 13:25:37 EST
For clarity sake:

After selecting "period as weekly" and "weekday as sunday" from the schedule tab under oscap policy creation

*) we could see below NULL values for 'day_of_month' and 'cron_line'.

2015-03-05 23:23:52 [I] Processing by ScaptimonyPoliciesController#create as HTML
2015-03-05 23:23:52 [I]   Parameters: {"utf8"=>"✓", "authenticity_token"=>"SiRic7p2ZM4sH0202fxc03z7I4+VYkW/p0RsXBnt6I4=", "policy"=>{"current_step"=>"Locations", "name"=>"oscap_policy3u", "description"=>"", "scap_content_id"=>"1", "scap_content_profile_id"=>"3", "period"=>"weekly", "weekday"=>"sunday", "day_of_month"=>"", "cron_line"=>"", "location_ids"=>[""], "organization_ids"=>["", "1"], "hostgroup_ids"=>[""]}, "commit"=>"Next"}
Comment 4 Shlomi Zadok 2015-03-09 04:23:13 EDT
Proposed fix upstream: https://github.com/OpenSCAP/foreman_openscap/pull/92
Comment 7 Kedar Bidarkar 2015-03-25 05:50:21 EDT
I am facing this issue again, 

a) selecting weekly, prompts also to fill in "day of month".
b) selecting monthly, prompts also to fill in   "weekday".

Tried with Satellite-6.1.0-RHEL-7-20150317.0
Comment 10 Kedar Bidarkar 2015-04-02 11:09:13 EDT
VERIFIED with sat6.1 Beta RC3.
Comment 11 Bryan Kearney 2015-08-11 09:31:30 EDT
This bug is slated to be released with Satellite 6.1.
Comment 12 errata-xmlrpc 2015-08-12 01:29:01 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2015:1592

Note You need to log in before you can comment on or make changes to this bug.