Disabling same-origin policy in Electron (need this to work with iframes)

I’ll try to be as short as possible since there’s no need for code - I put an iframe tag in my Electron app and I want JavaScript to retrieve some information from it but due to same-origin policy, I can’t do that. Can I disable it?

At the moment, when I do this

var validate = document.getElementById('validate');
            validate.onclick = function() {
                var input = document.getElementById('serial').value;
                var validator = document.createElement('iframe');
                validator.src = "http://awebsite.com/?wvkey=" + input;
                body.appendChild(validator);
                var status = validator.contentWindow.document.getElementById('status').innerHTML;
                if (status === "Key Status: Active") {
                    window.location.assign("../dashboard/index.html");
                }
                else {
                    window.location.assign("../support/keys/invalid/index.html");
                }
            }

It just displays the iframe in the background and that’s it. How can I fix this?
Note: I am the owner of the website in the iframe.