function openSODFile() {
    w2confirm('Are you sure you want to open a SOD? All unsaved data in the current one will be lost.', function btn(answer) {
        if (answer == "Yes") {
            const {remote} = require('electron')
            const {dialog} = remote
            const path = dialog.showOpenDialog({filters:[{name:"Case File",extensions:["fox"]}]});

            if(path == undefined) return;
            currentfile = path

            var fs = require('fs');

            var filebuffer = fs.readFileSync(path.toString());
            case_data = JSON.parse(filebuffer);

            if(case_data.hasOwnProperty(storage_format_version) && case_data.storage_format_version < storage_format_version){
                w2alert("You are opening a file created with a newer version of Aurora IR. Please upgrade to the newest version of Aurora IR and try again")
                return
            }

            if(case_data.storage_format_version< storage_format_version){
                updateVersion(case_data.storage_format_version)
            }

            w2ui.grd_timeline.records = case_data.timeline
            w2ui.grd_timeline.refresh()
            w2ui.grd_investigated_systems.records = case_data.investigated_systems
            w2ui.grd_investigated_systems.refresh()
            w2ui.grd_malware.records = case_data.malware
            w2ui.grd_malware.refresh()
            w2ui.grd_accounts.records = case_data.compromised_accounts
            w2ui.grd_accounts.refresh()
            w2ui.grd_network.records = case_data.network_indicators
            w2ui.grd_network.refresh()
            w2ui.grd_exfiltration.records = case_data.exfiltration
            w2ui.grd_exfiltration.refresh()
            w2ui.grd_osint.records = case_data.osint
            w2ui.grd_osint.refresh()
            w2ui.grd_systems.records = case_data.systems
            w2ui.grd_systems.refresh()
            w2ui.grd_actions.records = case_data.actions
            w2ui.grd_actions.refresh()
            w2ui.grd_evidence.records = case_data.evidence
            w2ui.grd_evidence.refresh()
            w2ui.grd_investigators.records = case_data.investigators
            w2ui.grd_investigators.refresh()
            w2ui.grd_casenotes.records = case_data.casenotes
            w2ui.grd_casenotes.refresh()

            w2ui['grd_timeline'].getColumn('owner').editable.items = case_data.investigators
            w2ui.grd_timeline.getColumn('event_host').editable.items = case_data.systems
            w2ui.grd_timeline.getColumn('event_source_host').editable.items = case_data.systems

            w2ui.main_layout.content('main', w2ui.grd_timeline);
            w2ui.sidebar.select('timeline')

            // check if its locked
            if (case_data.locked){
                w2alert("The SOD is locked by another analyst. Opening in Readonly mode.")
                lockedByMe = false
                activateReadOnly()
                stopAutoSave()
                startAutoUpdate()
            }
            else {

                requestLock(true)
            }

            w2ui.main_layout.content('main', w2ui.grd_timeline);
        }
    });
}
Opens SOD file from Disk or Share