Transferencia‎ > ‎

Proyectos Personales

PPProxy

#include <QNetworkConfiguration>
#include <QNetworkConfigurationManager>
#include <QNetworkSession>
    
    QT += network
    CONFIG += c++11
    
    QNetworkConfiguration cfg;
    QNetworkConfigurationManager ncm;
    auto nc = ncm.allConfigurations();

    for (auto &x : nc)
    {
        qDebug()<<x.name();
        if (x.bearerType() == QNetworkConfiguration::BearerWLAN)
        {
            if (x.name() == "Intia")
                cfg = x;
        }
    }

    auto session = new QNetworkSession(cfg, this);
    session->open();

@echo off
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v ProxyEnable /t REG_DWORD /d 1 /f
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v ProxyServer /t REG_SZ /d "proxy.exa.unicen.edu.ar:8080" /f
reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v ProxyOverride /t REG_SZ /d "" /f
SelectionFile type iconFile nameDescriptionSizeRevisionTimeUser
Comments