Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

cannot connect to example.com in iOS enterprise app

I'm facing a serious problem. I'm trying to make a enterprise app live.By using BetaBuilder I follows these steps:

myApp.ipa
manifest.plist
index.html

manifest.plist:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>items</key>
    <array>
        <dict>
            <key>assets</key>
            <array>
                <dict>
                    <key>kind</key>
                    <string>software-package</string>
                    <key>url</key>
                    <string>https://example.com/ios/myapp.ipa</string>
                </dict>
            </array>
            <key>metadata</key>
            <dict>
                <key>bundle-identifier</key>
                <string>com.com.myapp</string>
                <key>bundle-version</key>
                <string>1.0</string>
                <key>kind</key>
                <string>software</string>
                <key>title</key>
                <string>Myapp</string>
            </dict>
        </dict>
    </array>
</dict>
</plist>

and the index.html file:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<title>Myapp - Beta Release</title>
</head>
<body>

<div id="container">
  <h1>iOS 4.0 Users:</h1>
  <div class="link"><a href="itms-services://?action=download-manifest&url=https://example.com/ios/manifest.plist">Tap Here to Install</a>
  </div>
</div>

</body>
</html>

I even made the link http to https. But it always says :Cannot connect to example.com. Whats wrong with the setup?

like image 210
Poles Avatar asked Apr 10 '15 11:04

Poles


People also ask

How to trust enterprise developer iPhone?

To "trust" the certificate: Tap into your iPhone Settings > General > Device Management (or Profiles on some iPhones) Under the "Enterprise App" heading, you see a profile with the enterprise certificate name. Tap into that profile and then Trust it.

How to verify developer on iPhone?

Tap Settings > General > Profiles or Profiles & Device Management. Under the "Enterprise App" heading, you see a profile for the developer. Tap the name of the developer profile under the Enterprise App heading to establish trust for this developer. Then you see a prompt to confirm your choice.


1 Answers

Over-The-Air iOS distributions must be served from using SSL with a verified SSL certificate.

Now to distrubute OTA you must follow these steps.

1) Provide a link to your generated .plist file that contains the manifest for the application download. This link MUST be served over SSL with a verified SSL certificate. An example of a valid .plist file is such:

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
  <dict>
    <key>items</key>
    <array>
      <dict>
        <key>assets</key>
        <array>
          <dict>
            <key>kind</key>
            <string>software-package</string>
            <key>url</key>
            <string>https://[full download url].ipa</string>
          </dict>
        </array>
        <key>metadata</key>
        <dict>
          <key>bundle-identifier</key>
          <string><full bundle identifier></string>
          <key>bundle-version</key>
          <string>[version string]</string>
          <key>kind</key>
          <string>software</string>
          <key>title</key>
          <string>[software name]</string>
        </dict>
      </dict>
    </array>
  </dict>
</plist>

2) URL key in the .plist file must be served from a valid SSL certificate.

Now I am not 100% of your server setup but there is the possibility the web server does not respond correctly to the .plist extension as well as the .ipa extension. You must set your web server to understand the following file extension \ mime-type:

  • Extension: .plist
  • MimeType: application/xml

  • Extension: .ipa

  • MimeType: application/octet-stream

We had many problems at first getting our applications to be deployed over the air. The biggest hurdle was around the SSL certificate and MimeTypes.

One final comment, I am sure you have your own domain and arent using example.com in your links or plist files.

Cheers..

like image 168
Nico Avatar answered Oct 23 '22 03:10

Nico