Jump to content

stream_socket_client overwriting remote_host parameter


decogd

Recommended Posts

Hello, Diego here. I hope you guys can help me with this one. If i run the code below in my hosting space:

 

<?php

$errno = 0;
$errstr = '';
$socket_context = stream_context_create();
$smtp_conn = stream_socket_client(
    "smtp.mandrillapp.com:587",
    $errno,
    $errstr,
    10,
    STREAM_CLIENT_CONNECT,
    $socket_context
);
while (is_resource($smtp_conn) && !feof($smtp_conn))
{
    $str = fgets($smtp_conn, 515);
    echo $str;
    // If 4th character is a space, we are done reading, break the loop, micro-optimisation over strlen
    if ((isset($str[3]) and $str[3] == ' ')) break;
}

 

I get this:

 

220-server.dhdinc.com ESMTP Exim 4.80 #2 Wed, 06 May 2015 14:06:16 -0500 220-We do not authorize the use of this system to transport unsolicited, 220 and/or bulk e-mail.

 

As you can see this function is ignoring remote_host parameter completely and uses server.dhdinc.com instead of smtp.mandrillapp.com. How this can be? Any ideas?

 

Thanks.

Edited by decogd
Link to comment
Share on other sites

Hi boomba,

 

Thanks for your reply. Their API use cURL and Webservices which is very slow compared to using sockets. The code i posted is part from PhpMailer library, suddenly stopped working in my hosting after long time of working well. BTW my php version is 5.2.17 if anyone want to know.

Link to comment
Share on other sites

Banu agrees with all villagers after he teaches them how to use a sword. An army of villagers attack the palace of the king trying to regain the baby. Zangoora and his guards take the baby to the roof of the palace threatening Banu to surrender himself otherwise the king will throw the baby down.Bollywood's famous monkey during the Fifties Zippy, in a brink of no time snatches the baby from the hands of Zangoora hands the baby over to Mangal who rides his horse heading for the village. Before Mangal disappears one of Zangoora's brave soldiers Jairaj (a piece of information about actor Jairaj who was a very important actor in Bollywood after this letter) from a short distance throws his knife which goes right through heart of Mangal. Nevertheless the latter manages to reach to village with the baby in his hands stained with blood. louboutin shoes The union says the New Zealand tragedy, where two front counter workers at the Work and Income New Zealand (WINZ) office were killed and another two staff members badly injured, has serious implications for Australia's welfare network. s michael kors outlet

This is a commendable effort, the problem is after being diagnosed with a dementia, then the support can be a lottery. If you are fortunate enough to have family who will provide care you are lucky. The majority of people I have worked with over the years have had to rely on carers, as their families are unable, or in many cases, unwilling to do so. I applaud this gentleman for looking after his mother, it makes an enormous difference, as the more you know about a person life, the better able you are to understand how to provide the person centred care they need, which is vastly different in every case. What is a shame, is that whilst a lot of families rely on day care for a few hours of respite, the local governments are cutting back this service to the bare bones, in my opinion, they are quite willing to hand it over completely to the private sector,where staff have only the very basic training in dementia care. And whilst the government pays for tv ads for being a dementia buddy , with famous faces to promote the cause, if families had the right support from social services, with a budget to match, many families could be their loved ones buddy without resorting to strangers doing the job for them. louis vuitton outlet uk "It was there that I sampled gourmet cookies from some of the best bakers in the country," he said. "The funny part is that most of them were variations on the chocolate chip cookies or the monster cookies we all had as kids.

The accusation caught Olynyk by surprise. ray ban outlet Fresno State's Davante Adams, the Packers' second-round draft choice on Friday night, ranked merely 15th in 40-yard dash time on a subjective list of the top 17 wide receivers in the draft. n coach online outlet

Ripon鈥檚 claim as the site for the new university of the North, and its fight to save its hospital, threatened with closure, were matters referred to by the Mayor, Alderman W H Parnaby, and the Dean, the Very Rev F Llewelyn Hughes, in civic dinner speeches at Ripon on Tuesday evening. michael kors outlet online The starters did a really good job and they cause a lot of turnovers as well, Bayless said. But our group that comes in, we just really try to get out there and pressure a little more.

j Tamerlan Tsarnaev was killed that night; his younger brother is on trial now in a federal death penalty case in Boston. michaelkorsonlineoutlet.eu.com Samantha Page, chief executive of advocacy group Early Childhood Australia, says wages are another driver of costs in the sector, as well as rising rents. http://michaelkorsonlineoutlet.eu.com

Table: Stanhope Bonny Moor Hen 210; Wolsingham Club 179; Stanhope Grey Bull 162; Rookhope Club 141; Blanchland Sports Club 133; Frosterley Inn 129; New Market 126; Blue Bell 123; Golden Lion 120; Cowshill Hotel 111; Eastgate Cross Keys 108; Westgate Hare Hounds 85; Stanhope Pack Horse 77. true religion jeans Is there a future for hill farming? http://michaelkorsonlineoutlet.eu.com

In an email, Jackson's spokesman Matt Dravitzki said fans can expect "a surprise or two" in this week's trailer, "but I can't say anything more than that!" coach outlet online What will it take for Egypt to wake-up to the fact that enemies of the state, who think nothing of shooting, bombing and burning to achieve their goals, must be treated with an iron fist? The international community condemns its judiciary for issuing mass death sentences, but few of those sentences are being carried out. w ray ban outlet

A decision on the plan to demolish the building could be made next month (April). coach outlet *You can鈥檛 tell a pelican to stick its bill up its backside.

They come at a time when the administration of Prime Minister Shinzo Abe is preparing new security legislation to expand the range of SDF operations, including those involving collective self-defense, which had long been banned under the Constitution. louis vuitton outlet East Hills

I know, some of you are saying, 鈥淩ebecca, we have the Chamber and Thrive鈥檚 Advance Now strategy!鈥?It鈥檚 not enough. It鈥檚 riddled with safe words like 鈥渃oordinate鈥?and 鈥渇acilitate.鈥?These are white-collar events that will be carried out during bankers鈥?hours by men in suits. By contrast, most of the exciting economic development stuff I see in Madison happens online or in bars, after hours, carried out by folks who don鈥檛 own suits. coach outlet uk Tickets for the carvery meal are strictly limited and cost from 拢13.50 so early booking is advisable. Either telephone the hotel on 01833 638223 or email: mark@jerseyfarm.co.uk to reserve your places.

By selling my collection, I met a lot of people who paid a lot of money for things, he said. ray ban outlet Even unruly colliery officials could face relocation to the Low Side.

y The whole lot need 'Sorting-Out' in every level from Chief Constables and right through the ranks to the latest recruits. http://michaelkorsoutlet.celebrationoffood.co.uk The father-of-three, born Robert Christopher Nankeville, leaves the sadness and romance to his well-known co-stars Lee Latchford-Evans, the Steps singer, as Prince/Beast and popular Tracy Beaker star Dani Harmer as Beauty.

Interns Corinne Burgermeister and Sam Garigliano contributed to this report.聽 coach outlet online The Hilltoppers are one of five teams making a consecutive trip to the state final and of those schools arguably has gone through the most changes since last season. z louboutin outlet

鈥淏ut it was alright a week ago. It would鈥檝e been disrespectful to leave anyone out. Liam Hatch was magnificent at Harrogate, but I put Alan White in, who has been magnificent this season.鈥?michael kors outlet See also:

x This success comes at a price, however. Shares trade at 30 times earnings forecasts -- a pretty expensive valuation. true religion outlet The death toll from the quake inNepalis now over 4000 and about 7500 people are reported to be injured. Unicef says nearly 1 million children in earthquake affected areas are in urgent need of humanitarian assistance. Aid workers report dwindling supplies of water and food, power outages, and downed mobile networks. Limited access to clean water and hygiene has increased the risk of diseases spreading. f

Starting with McClean, the Republic of Ireland international has had a whirlwind year and the effects have clearly taken their toll. When he was outstanding last season it was largely because he was an unknown quantity, basically being asked to get down the line and deliver crosses. michael kors outlet Before completing full-time studies I stacked shelves, worked in pubs, delivered ice cream, fitted heating... you name it. I have never had a bad job, they are all good if there is a result at the end. It was people who made jobs bad. I had a boss who continually verbally abused people in his charge. I left and found something else before I got myself into trouble. He did teach me a lot though about leadership. michael kors outlet online

鈥淲e want the World Cup to not just be a window-dressing but a shop window for cricket at the highest level. Maybe only 10 (teams) initially, but the idea is to grow it.鈥?louboutin outlet p christian louboutin outlet

Sidebottom took eleven wickets in eight NayWest T20 Blast matches last season, but his last List A appearance came in a 40-over match against the Unicorns in May 2013. http://michaelkorsoutlet.celebrationoffood.co.uk The 拢7m project was supported by 拢1m from the Government鈥檚 flagship Regional Growth Fund, and should benefit from homeowners鈥?growing passion for goods made in the UK.

But March Madness isn't just about brackets and buzzer beaters. It's also about food. louis vuitton outlet online I don't want to talk about myself, I talk about the players, he said. x true religion outlet

He was driving a mineral train from Shildon to Stockton when he stopped at the junction to have more wagons attached. He got down and went under the locomotive to do some oiling. He was there when the boiler exploded, giving him no chance of surviving. coach outlet It said the ads "at no time demonstrated any dangerous driving", and there was no indication that speed limits were broken.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.