Giter Site home page Giter Site logo

ga-cyberworkforceacademy / labtainers Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mfthomps/labtainers

0.0 0.0 0.0 254.76 MB

Labtainers: A Docker-based cyber lab framework

Home Page: https://my.nps.edu/web/c3o/labtainers

Shell 6.74% Python 49.07% Makefile 0.21% TeX 12.81% HTML 14.23% C 2.53% C++ 0.97% JavaScript 5.07% PHP 0.15% CSS 3.78% Java 4.34% Tcl 0.03% Batchfile 0.01% Assembly 0.01% Dockerfile 0.02% PostScript 0.02% Classic ASP 0.02%

labtainers's People

Contributors

acantrell2009 avatar danielliao22 avatar ga-cyberworkforceacademy avatar harperaa avatar mfthomps avatar nathanmuccino avatar svenaelterman avatar

Watchers

 avatar

labtainers's Issues

Add API call to Canvas

Is your feature request related to a problem? Please describe.
Currently, the output for lab completion is a json formatted dump saved to a web server for student progress and grade tracking. This needs to parsed with another script and manually entered as a grade in Canvas.

Describe the solution you'd like
Add functionality that would pass the information for a student's assignment to Canvas with an API call.

Canvas LMS API Docs

[BUG]-install_script

Describe the bug
install-labtainer.sh doesn't properly install due to the way the directory is structured

To Reproduce

./install-labtainer.sh

There are references to a 'trunk' folder that doesn't seem to exist

Add URL Pointer to Lab Docs

Is your feature request related to a problem? Please describe.
Currently, the lab prompts are reference via the "read_first.txt" file and provide a local path reference to a pre-generated pdf.

Describe the solution you'd like
The read_first.txt file for each lab prompt link needs to be re-pointed to the appropriate GTALabs GitHub Page URL from the GTALabs Project.

Example pulled from acl lab:

The lab manual is at 
   file://LAB_DOCS/acl.pdf

You may open these by right clicking
and select "Open Link".
  • acl
  • metasploit
  • nix-commands
  • nmap-discovery
  • nmap-ssh
  • packet-instrospection
  • pass-crack
  • snort
  • sql-inject
  • tcpip
  • telnet
  • arpspoof
  • local-dns
  • xsite

[FEATURE]Add function to push labtainer results to web server

Is your feature request related to a problem? Please describe.
Currently, the output for lab completion is a json formatted dump saved to a local directory of the Labtainer host VM. This needs to be redirected to a web server for student progress and grade tracking.

Describe the solution you'd like
Add functionality that would post json dump to a web server using the http.server python module.

The code for assessing results and generating student reports starts at line 417 in instructor.py. Snippet below:

    ''' assess the results and generate simple report '''
    for email_labname in student_list:
        lab_dir_name = os.path.join(MYHOME, email_labname)
        grades = Grader.ProcessStudentLab(lab_dir_name, lab_id_name, logger)
        student_id = email_labname.rsplit('.', 1)[0]
        LabIDStudentName = '%s : %s : ' % (lab_id_name, student_id)

        # Add student's grades
        store_student_grades(gradesjson, email_labname, grades)

        # Add student's lab counter (if exists)
        student_lab_count = LabCount.getLabCount(lab_dir_name, lab_id_name, logger)
        store_student_labcount(gradesjson, email_labname, student_lab_count)

    #print "grades (in JSON) is "
    #print gradesjson

    # Output <labname>.grades.json
    gradesjsonname = os.path.join(MYHOME, "%s.grades.json" % lab_id_name)
    gradesjsonoutput = open(gradesjsonname, "w")
    try:
        jsondumpsoutput = json.dumps(gradesjson, indent=4)
    except:
        print('json dumps failed on %s' % gradesjson)
        exit(1)
    #print('dumping %s' % str(jsondumpsoutput))
    gradesjsonoutput.write(jsondumpsoutput)
    gradesjsonoutput.write('\n')
    gradesjsonoutput.close()

    if do_unique:
        # Output <labname>.unique.json
        uniquejsonname = os.path.join(MYHOME, "%s.unique.json" % lab_id_name)
        uniquejsonoutput = open(uniquejsonname, "w")
        try:
            jsondumpsoutput = json.dumps(uniquejson, indent=4)
        except:
            print('json dumps failed on %s' % uniquejson)
            exit(1)
        #print('dumping %s' % str(jsondumpsoutput))
        uniquejsonoutput.write(jsondumpsoutput)
        uniquejsonoutput.write('\n')
        uniquejsonoutput.close()

    # Output <labname>.grades.txt
    gradestxtname = os.path.join(MYHOME, "%s.grades.txt" % lab_id_name)
    GenReport.CreateReport(gradesjsonname, gradestxtname, check_watermark)
    if do_unique:
        GenReport.UniqueReport(uniquejsonname, gradestxtname)

    # Inform user where the 'grades.txt' are created
    print("Grades are stored in '%s'" % gradestxtname)
    return 0

if __name__ == '__main__':
    sys.exit(main())

nmap-discovery lab (extra/broke terminal)

when the nmap-discovery labtainer is deployed, in addition to the docker, it deploys a terminal with a portion of the instructions. This is not rendering properly and is un-needed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.