Skip to content

Testing of Security Manager checklist #790

Description

@alisevych

Initial set-up

Check that the IntelliJ Idea UTBot plugin can be successfully installed

  • Choose appropriate workflow from the list - with Security Manager included - plugin build used
  • Download plugin
  • Open IntelliJ IDE
  • Remove previously installed UTBot plugin
  • Install the downloaded plugin

Go through manual scenarios

Basic security

Project with JDK 17 - blocked as UTBot is incompatible with JDK 12+

Permissions

  • add PropertyPermission in ~.utbot\sandbox.policy - check test for property is not in sandbox, execute
  • add "permission java.io.FilePermission "<>", "read";" - check test for read not in sandbox, execute
  • add AllPermission in ~.utbot\sandbox.policy - check NO tests are in sandbox, try to execute (carefully!!!)
  • corrupt permission - check how UTBot fails - found Too many permissions file rereads - can slow down much #796
  • empty file
  • remove ~.utbot\sandbox.policy file - check generated tests are in sandbox

Test rendering

Code structures

Activity

  1. self-assigned this
    on Aug 25, 2022
  2. moved this to Todo in UTBot Javaon Aug 25, 2022
  3. alisevych commented on Aug 26, 2022

    @alisevych
    MemberAuthor

    @Markoutte @korifey
    Please advise if UTBot needs to detect the restricted operations in Threads?
    The following method is not executed - AccessControlException is thrown (in logs) - that's Ok.
    But the generated tests are not disabled due to Sandbox

    public int read() throws Throwable {
            Thread t = new Thread("fileRead") {
                public void run()  {
                    try {
                        new File("a.txt").createNewFile();
                    } catch (IOException e) {
                        throw new RuntimeException(e);
                    }
                }
            };
            t.start();
            Thread.sleep(500);
            return 10;
        }
  4. changed the title [-]Manual testing checklist for Security Manager[/-] [+]Test checklist for Security Manager[/+] on Aug 30, 2022
  5. Repository owner moved this from Todo to Done in UTBot Javaon Sep 12, 2022
  6. changed the title [-]Test checklist for Security Manager[/-] [+]Manual testing of Security Manager checklist[/+] on Sep 14, 2022
  7. changed the title [-]Manual testing of Security Manager checklist[/-] [+]Testing of Security Manager checklist[/+] on Sep 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

ctg-qaIssue is related to QA process

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions