Exemplo n.º 1
0
 def add_ldap_rule_to_s_group(self, s_group_name, s_group_id):
     """
     Navigates to security group detail page. Opens TCP 389 port to all addresses.
     :param s_group_name:
     :param s_group_id:
     """
     BasePage(self).goto_security_groups_view_via_menu()
     SecurityGroupView(self).click_action_view_s_group_details_on_view_page(s_group_id)
     SecurityGroupDetailPage(self, s_group_name).add_rule_to_s_group_open_to_all_addresses("TCP port 389")
Exemplo n.º 2
0
 def add_tcp_22_rule_to_s_group(self, s_group_name, s_group_id):
     """
     Navigates to security group detail page. Opens TCP 22 port to user's IP.
     :param s_group_name:
     :param s_group_id:
     """
     BasePage(self).goto_security_groups_view_via_menu()
     SecurityGroupView(self).click_action_view_s_group_details_on_view_page(s_group_id)
     SecurityGroupDetailPage(self, s_group_name).add_rule_to_s_group_open_to_my_ip("TCP port 22")
Exemplo n.º 3
0
 def add_custom_tcp_rule_to_s_group(self, s_group_name, s_group_id):
     """
     Navigates to security group detail page. Opens TCP port 22-3389 to default group.
     :param s_group_name:
     :param s_group_id:
     """
     BasePage(self).goto_security_groups_view_via_menu()
     SecurityGroupLanding(self).click_action_view_s_group_details_on_view_page(s_group_id)
     SecurityGroupDetailPage(self, s_group_name).add_custom_tcp_rule_open_to_default_group("22","3389")
Exemplo n.º 4
0
 def delete_security_group_from_detail_page(self, sgroup_name, s_group_id):
     """
     Navigates to security group detail page. Deletes security group.
     :param sgroup_name:
     :param s_group_id:
     """
     BasePage(self).goto_security_groups_view_via_menu()
     SecurityGroupLanding(self).click_action_view_s_group_details_on_view_page(s_group_id)
     SecurityGroupDetailPage(self, sgroup_name).click_action_delete_s_group_on_detail_page()
     DeleteScurityGroupDialog(self).delete_s_group()
     SecurityGroupLanding(self).verify_s_group_not_present(sgroup_name)
Exemplo n.º 5
0
 def create_security_group_from_view_page(self, s_group_name, s_group_description):
     """
     Creates security group from S. groups view page without adding rules or tags.
     :param s_group_name:
     :param s_group_description:
     """
     BasePage(self).goto_security_groups_view_via_menu()
     SecurityGroupLanding(self).click_create_new_s_group_button()
     CreateScurityGroupDialog(self).create_s_group(s_group_name, s_group_description)
     s_group_id = SecurityGroupDetailPage(self, s_group_name).get_s_group_id()
     return {'s_group_name': s_group_name, 's_group_id':s_group_id}
Exemplo n.º 6
0
 def create_security_group_from_dashboard(self, s_group_name, s_group_description):
     """
     Creates security group from dashboard without adding rules or tags.
     :param s_group_name:
     :param s_group_description:
     """
     BasePage(self).goto_dashboard_via_menu()
     Dashboard(self).click_create_s_group_link_from_dashboard()
     CreateScurityGroupDialog(self).create_s_group(s_group_name, s_group_description)
     s_group_id = SecurityGroupDetailPage(self, s_group_name).get_s_group_id()
     return {'s_group_name': s_group_name, 's_group_id':s_group_id}
Exemplo n.º 7
0
 def create_sesecurity_group_with_rules(self, s_group_name, s_group_description, rule_open_to_all, rule_open_to_default_group, rule_open_to_default_group_port_begin, rule_open_to_default_group_port_end):
     BasePage(self).goto_dashboard_via_menu()
     Dashboard(self).click_create_s_group_link_from_dashboard()
     CreateScurityGroupDialog(self).create_s_group_with_rules(s_group_name, s_group_description, rule_open_to_all, rule_open_to_default_group, rule_open_to_default_group_port_begin, rule_open_to_default_group_port_end)
     s_group_id = SecurityGroupDetailPage(self, s_group_name).get_s_group_id()
     return {'s_group_name': s_group_name, 's_group_id':s_group_id}