src/dird/mac.c
static bool send_store_addr_to_sd(JCR *jcr, char *Job, char *sd_auth_key,
                 STORE *store, char *store_address, uint32_t store_port)
{
   int tls_need = BNET_TLS_NONE;

   /* TLS Requirement */
   if (store->tls_enable) {
      if (store->tls_require) {
         tls_need = BNET_TLS_REQUIRED;
      } else {
         tls_need = BNET_TLS_OK;
      }
   }

   /*
    * Send Storage address to the SD client
    */
   Dmsg2(200, "=== Job=%s sd auth key=%s\n", Job, sd_auth_key);
   jcr->store_bsock->fsend(storaddr, store_address, store_port,
      tls_need, Job, sd_auth_key);
   if (!response(jcr, jcr->store_bsock, OKstore, "Storage", DISPLAY_ERROR)) {
      Dmsg4(050, "Response fail for: JobId=%d storeaddr=%s:%d Job=%s\n",
           jcr->JobId, store_address, store_port, Job);
      Jmsg3(jcr, M_FATAL, 0, "Response failure: storeddr=%s:%d Job=%s\n",
            store_address, store_port, Job);

      return false;
   }
   return true;
}
/*
 * Send storage address and authentication to deblock the other
 *   job.
 */
Send storage address and authentication to deblock the other
job.
Send storage address and authentication to deblock the other job .
static bool send_store_addr_to_sd(JCR *jcr, char *Job, char *sd_auth_key,
                 STORE *store, char *store_address, uint32_t store_port)
{
   int tls_need = BNET_TLS_NONE;
   if (store->tls_enable) {
      if (store->tls_require) {
         tls_need = BNET_TLS_REQUIRED;
      } else {
         tls_need = BNET_TLS_OK;
      }
   }
   Dmsg2(200, "=== Job=%s sd auth key=%s\n", Job, sd_auth_key);
   jcr->store_bsock->fsend(storaddr, store_address, store_port,
      tls_need, Job, sd_auth_key);
   if (!response(jcr, jcr->store_bsock, OKstore, "Storage", DISPLAY_ERROR)) {
      Dmsg4(050, "Response fail for: JobId=%d storeaddr=%s:%d Job=%s\n",
           jcr->JobId, store_address, store_port, Job);
      Jmsg3(jcr, M_FATAL, 0, "Response failure: storeddr=%s:%d Job=%s\n",
            store_address, store_port, Job);
      return false;
   }
   return true;
}
static bool send_store_addr_to_sd ( JCR * jcr , char * Job , char * sd_auth_key , STORE * store , char * store_address , uint32_t store_port ) { int tls_need = BNET_TLS_NONE ; if ( store -> tls_enable ) { if ( store -> tls_require ) { tls_need = BNET_TLS_REQUIRED ; } else { tls_need = BNET_TLS_OK ; } } Dmsg2 ( 200 , " \n " , Job , sd_auth_key ) ; jcr -> store_bsock -> fsend ( storaddr , store_address , store_port , tls_need , Job , sd_auth_key ) ; if ( ! response ( jcr , jcr -> store_bsock , OKstore , " " , DISPLAY_ERROR ) ) { Dmsg4 ( 050 , " \n " , jcr -> JobId , store_address , store_port , Job ) ; Jmsg3 ( jcr , M_FATAL , 0 , " \n " , store_address , store_port , Job ) ; return false ; } return true ; }
Send storage address and authentication to deblock the other
   job.
Send storage address and authentication to deblock the other job .
/* TLS Requirement */ /*
    * Send Storage address to the SD client
    */