--- chan_sip_old.c	2006-10-18 03:37:18.000000000 +0700
+++ chan_sip_new.c	2006-10-20 16:48:21.000000000 +0700
@@ -605,6 +605,7 @@ static struct sip_pvt {
 	unsigned int flags;			/*!< SIP_ flags */	
 	int timer_t1;				/*!< SIP timer T1, ms rtt */
 	unsigned int sipoptions;		/*!< Supported SIP sipoptions on the other end */
+	int silence_supp;				/*!< Show/Hide silenceSupp from header */
 	int capability;				/*!< Special capability (codec) */
 	int jointcapability;			/*!< Supported capability at both ends (codecs ) */
 	int peercapability;			/*!< Supported peer capability */
@@ -768,6 +769,7 @@ struct sip_peer {
 	char cid_num[80];		/*!< Caller ID num */
 	char cid_name[80];		/*!< Caller ID name */
 	int callingpres;		/*!< Calling id presentation */
+	int silence_supp; /*!< Show/Hide silenceSupp from header */
 	int inUse;			/*!< Number of calls in use */
 	int call_limit;			/*!< Limit of concurrent calls */
 	char vmexten[AST_MAX_EXTENSION]; /*!< Dialplan extension for MWI notify message*/
@@ -1879,6 +1881,7 @@ static int create_addr_from_peer(struct 
 	}
 
 	ast_copy_flags(r, peer, SIP_FLAGS_TO_COPY);
+	r->silence_supp = peer->silence_supp;
 	r->capability = peer->capability;
 	r->prefs = peer->prefs;
 	if (r->rtp) {
@@ -4605,9 +4608,10 @@ static int add_sdp(struct sip_request *r
 				    &a_audio_next, &a_audio_left,
 				    debug);
 	}
-
-	ast_build_string(&a_audio_next, &a_audio_left, "a=silenceSupp:off - - - -\r\n");
-
+	/* Show hide silenceSupp from header */
+	if (p->silence_supp){
+			ast_build_string(&a_audio_next, &a_audio_left, "a=silenceSupp:off ----\r\n");
+	}
 	if ((m_audio_left < 2) || (m_video_left < 2) || (a_audio_left == 0) || (a_video_left == 0))
 		ast_log(LOG_WARNING, "SIP SDP may be truncated due to undersized buffer!!\n");
 
@@ -12367,6 +12371,7 @@ static struct sip_peer *build_peer(const
 	peer->rtpkeepalive = global_rtpkeepalive;
 	peer->maxms = default_qualify;
 	peer->prefs = prefs;
+	perr->silence_supp = TRUE;
 	oldha = peer->ha;
 	peer->ha = NULL;
 	peer->addr.sin_family = AF_INET;
@@ -12530,6 +12535,14 @@ static struct sip_peer *build_peer(const
 				ast_log(LOG_WARNING, "Qualification of peer '%s' should be 'yes', 'no', or a number of milliseconds at line %d of sip.conf\n", peer->name, v->lineno);
 				peer->maxms = 0;
 			}
+		} else if (!strcasecmp(v->name, "silencesupp")) {
+				if (!strcasecmp(v->value, "hide")) {
+					peer->silence_supp = FALSE;
+				} else if (!strcasecmp(v->value, "show")) {
+					peer->silence_supp = TRUE;
+				} else {
+					ast_log(LOG_WARNING, "silencesupp bad param on %s just use: 'show' or 'hide'\n", peer->name);
+				}
 		}
 		/* else if (strcasecmp(v->name,"type"))
 		 *	ast_log(LOG_WARNING, "Ignoring %s\n", v->name);
