How to access iPhone Settings to make use of proxy configurations?

Hi all,

I'm trying send POST info to a http, but I noticed that it doesn't really work when internet conectivity is behind a proxy.

My question is, how can I send to unity the proxy settings used on iPhone for Internet access so I can use the system default adress, port, user and password?

Thanks in advance

the only thing i could find is to use native objective-C code (in a native plugin) to obtain proxy settings:

std::string getProxyName()
{
    CFDictionaryRef dicRef = CFNetworkCopySystemProxySettings();
    const CFStringRef proxyCFstr = (const CFStringRef)CFDictionaryGetValue(dicRef, (const void*)kCFNetworkProxiesHTTPProxy);
    char buffer[4096];
    memset(buffer, 0, 4096);
    if (CFStringGetCString(proxyCFstr, buffer, 4096, kCFStringEncodingUTF8))
    {
        return std::string(buffer);
    }
    return "";
}


int CDownloadThread::getProxyPort()
{
    CFDictionaryRef dicRef = CFNetworkCopySystemProxySettings();
    const CFNumberRef portCFnum = (const CFNumberRef)CFDictionaryGetValue(dicRef, (const void*)kCFNetworkProxiesHTTPPort);

    SInt32 port;
    if (CFNumberGetValue(portCFnum, kCFNumberSInt32Type, &port))
    {
        return port;
    }
    return -1;
}