title: How to find out which https fields a server wants for a successful response?
body: <p>Im currently in an internship and i want to build a android app thats capable of connecting to the companies email server.</p>
  
  <p>But to be able to connect a device to the server i need to know which fields the server expects inside a clients https request in addition to working user/pass credentials. </p>
  
  <p>I tried getting informations about the packets sent with tcpdumb (server and client side) and wireshark, but they seem to be encrypted or not readable, which makes sense considering it's https.</p>
  
  <pre><code>    &lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt;
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
  &lt;head&gt;
  &lt;title&gt;Roundcube Webmail :: Willkommen bei Roundcube Webmail&lt;/title&gt;
  &lt;meta name="Robots" content="noindex,nofollow" /&gt;
  &lt;meta http-equiv="X-UA-Compatible" content="IE=EDGE" /&gt;
  &lt;link rel="index" href="./?_task=login" /&gt;
  &lt;link rel="shortcut icon" href="skins/classic/images/favicon.ico"/&gt;
  &lt;link rel="stylesheet" type="text/css" href="skins/classic/common.min.css?s=1418906028" /&gt;
  
  &lt;meta http-equiv="content-type" content="text/html; charset=UTF-8" /&gt;
  &lt;link rel="stylesheet" type="text/css" href="plugins/jqueryui/themes/classic/jquery-ui-1.9.2.custom.css?s=1418906027"&gt;
  &lt;script src="program/js/jquery.min.js?s=1418906027" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="program/js/common.min.js?s=1418906027" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="program/js/app.min.js?s=1418906027" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script src="program/js/jstz.min.js?s=1418906027" type="text/javascript"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
  /* &lt;![CDATA[ */
  
  var rcmail = new rcube_webmail();
  rcmail.set_env({"task":"login","x_frame_options":"sameorigin","standard_windows":false,"cookie_domain":"","cookie_path":"\/","cookie_secure":true,"skin":"classic","refresh_interval":60,"session_lifetime":600,"action":"","comm_path":".\/?_task=login","compose_extwin":false,"date_format":"yy-mm-dd","request_token":"029873c7042111df50bf712676a72046"});
  rcmail.gui_container("loginfooter","bottomline");
  rcmail.add_label({"loading":"Wird geladen...","servererror":"Serverfehler!","connerror":"Verbindungsfehler (Fehler beim Erreichen des Servers)!","requesttimedout":"Zeit\u00fcberschreitung der Anforderung","refreshing":"Aktualisieren\u2026"});
  rcmail.gui_object('message', 'message');
  rcmail.gui_object('loginform', 'form');
  /* ]]&gt; */
  &lt;/script&gt;
  
  &lt;script type="text/javascript" src="plugins/jqueryui/js/jquery-ui-1.9.2.custom.min.js?s=1418906027"&gt;&lt;/script&gt;
  &lt;script type="text/javascript" src="plugins/jqueryui/js/i18n/jquery.ui.datepicker-de.js?s=1418906027"&gt;&lt;/script&gt;
  &lt;/head&gt;
  &lt;body&gt;
  
  &lt;img src="skins/classic/images/roundcube_logo.png" id="logo" border="0" style="margin:0 11px" alt="Roundcube Webmail"&gt;
  
  &lt;div id="message"&gt;&lt;/div&gt;
  
  &lt;div id="login-form"&gt;
  &lt;div class="boxtitle"&gt;Willkommen bei Roundcube Webmail&lt;/div&gt;
  &lt;div class="boxcontent"&gt;
  
  &lt;form name="form" method="post" action="./?_task=login"&gt;
  &lt;input type="hidden" name="_token" value="029873c7042111df50bf712676a72046"&gt;
  &lt;input type="hidden" name="_task" value="login"&gt;&lt;input type="hidden" name="_action" value="login"&gt;&lt;input type="hidden" name="_timezone" id="rcmlogintz" value="_default_"&gt;&lt;input type="hidden" name="_url" id="rcmloginurl" value=""&gt;&lt;table summary="" border="0"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td class="title"&gt;&lt;label for="rcmloginuser"&gt;Benutzername&lt;/label&gt;
  &lt;/td&gt;
  &lt;td class="input"&gt;&lt;input name="_user" id="rcmloginuser" required="required" autocapitalize="off" autocomplete="off" type="text"&gt;&lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;&lt;td class="title"&gt;&lt;label for="rcmloginpwd"&gt;Passwort&lt;/label&gt;
  &lt;/td&gt;
  &lt;td class="input"&gt;&lt;input name="_pass" id="rcmloginpwd" required="required" autocapitalize="off" autocomplete="off" type="password"&gt;&lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
  &lt;/table&gt;
  &lt;p class="formbuttons"&gt;&lt;input type="submit" id="rcmloginsubmit" class="button mainaction" value="Anmelden"&gt;&lt;/p&gt;
  
  &lt;/form&gt;
  
  &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;noscript&gt;
    &lt;p id="login-noscriptwarning"&gt;Warnung: Dieser Webmail-Service erfordert Javascript. Um ihn zu benutzten aktivieren Sie Javascript in ihren Browser-Einstellungen.&lt;/p&gt;
  &lt;/noscript&gt;
  
  &lt;div id="login-bottomline"&gt;
    Roundcube Webmail 
  
  &lt;/div&gt;
  
  
  
  &lt;script type="text/javascript"&gt;
  /* &lt;![CDATA[ */
  
  $(document).ready(function(){ 
  rcmail.init();
  var images = ["skins\/classic\/images\/icons\/folders.png","skins\/classic\/images\/mail_footer.png","skins\/classic\/images\/taskicons.gif","skins\/classic\/images\/display\/loading.gif","skins\/classic\/images\/pagenav.gif","skins\/classic\/images\/mail_toolbar.png","skins\/classic\/images\/searchfield.gif","skins\/classic\/images\/messageicons.png","skins\/classic\/images\/icons\/reset.gif","skins\/classic\/images\/abook_toolbar.png","skins\/classic\/images\/icons\/groupactions.png","skins\/classic\/images\/watermark.gif"];
              for (var i=0; i&lt;images.length; i++) {
                  img = new Image();
                  img.src = images[i];
              }
  });
  /* ]]&gt; */
  &lt;/script&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>This is the code from the clients login page, is there a way i can come up with what the server wants based on this code? 
  I have no experience with php whatsover but i built a rest api + client in java last semester.</p>
  
  <p>Thanks for any help!</p>