By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,953 Members | 1,143 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,953 IT Pros & Developers. It's quick & easy.

Sending email using SMTPMail requires user to be administrator on the server???

P: n/a
Hi,

I have built an webapp in C# that uses SMTPMail to send mail to users.
When I installed it on the prodserver everything worked fine for me, but the
users can not send mail.
They get Access denied. If I add them to the administrator group of the
server everything works fine.

I have set
<identity impersonate="true"/>
in my web.config.

And tried to add users in my local SMTP Virtuall Server.
But Im using an external Exchange as my SMTP server in my code.

Is there anything else I need to do to let the users send email? I read that
I need
to grant permissions in tha ACL(?), for users to send emails i ASP.NET?

Would be very greateful if anyone could help me!!

/Robert Pettersson
Nov 18 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
AS well as setting "identity impersonate" to true, did you set which user to
impersonate.

i.e.
<identity impersonate="true" userName="DMN\UserName" password="password" />

"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:OT**************@TK2MSFTNGP09.phx.gbl...
Hi,

I have built an webapp in C# that uses SMTPMail to send mail to users.
When I installed it on the prodserver everything worked fine for me, but
the
users can not send mail.
They get Access denied. If I add them to the administrator group of the
server everything works fine.

I have set
<identity impersonate="true"/>
in my web.config.

And tried to add users in my local SMTP Virtuall Server.
But Im using an external Exchange as my SMTP server in my code.

Is there anything else I need to do to let the users send email? I read
that
I need
to grant permissions in tha ACL(?), for users to send emails i ASP.NET?

Would be very greateful if anyone could help me!!

/Robert Pettersson

Nov 18 '05 #2

P: n/a
joe

I am not sure if you need to do this but have you tried
with Deny users="?" //deny unauthenticated users

in the web config,
-----Original Message-----
Hi,

I have built an webapp in C# that uses SMTPMail to send mail to users.When I installed it on the prodserver everything worked fine for me, but theusers can not send mail.
They get Access denied. If I add them to the administrator group of theserver everything works fine.

I have set
<identity impersonate="true"/>
in my web.config.

And tried to add users in my local SMTP Virtuall Server.
But Im using an external Exchange as my SMTP server in my code.
Is there anything else I need to do to let the users send email? I read thatI need
to grant permissions in tha ACL(?), for users to send emails i ASP.NET?
Would be very greateful if anyone could help me!!

/Robert Pettersson
.

Nov 18 '05 #3

P: n/a

When I try to set a specific user I get a error:

Access to the path "C:\WINNT\Microsoft.NET\Framework\v1.1.4322\Tempor ary
ASP.NET Files\internalfundtrades\8b42c84e\34a38a07\hash.we b" is denied.

But I dont really want the user to impersonate another user. Beacuse I want
to pick up which logged on user it is to log the actions.
My application is used on intranet only, and I dont allow anonymous access.
This is an update to my application, I used to have a VB6 component
that sent email using CDO, and that worked fine.

/Robert
"GrantMagic" <gr***@magicalia.com> wrote in message
news:eP**************@TK2MSFTNGP11.phx.gbl...
AS well as setting "identity impersonate" to true, did you set which user to impersonate.

i.e.
<identity impersonate="true" userName="DMN\UserName" password="password" />
"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:OT**************@TK2MSFTNGP09.phx.gbl...
Hi,

I have built an webapp in C# that uses SMTPMail to send mail to users.
When I installed it on the prodserver everything worked fine for me, but
the
users can not send mail.
They get Access denied. If I add them to the administrator group of the
server everything works fine.

I have set
<identity impersonate="true"/>
in my web.config.

And tried to add users in my local SMTP Virtuall Server.
But Im using an external Exchange as my SMTP server in my code.

Is there anything else I need to do to let the users send email? I read
that
I need
to grant permissions in tha ACL(?), for users to send emails i ASP.NET?

Would be very greateful if anyone could help me!!

/Robert Pettersson


Nov 18 '05 #4

P: n/a
impersonating a user will not change which user is logging the actions, that
should be handeled within the application. Impersonating a user will merely
impersonate that user for actions on the server .. like sending the mail.
In you application you can then log which user sent the mail, or speficy
that in the from address.

If this solution is still viable for you, then about that error:
Is the user your impersonating an administrator on the server?
Have you tried restarting IIS?
If that fails, post a question of search on Google

Hope this can help you out

Grant

"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:eE**************@TK2MSFTNGP11.phx.gbl...

When I try to set a specific user I get a error:

Access to the path "C:\WINNT\Microsoft.NET\Framework\v1.1.4322\Tempor ary
ASP.NET Files\internalfundtrades\8b42c84e\34a38a07\hash.we b" is denied.

But I dont really want the user to impersonate another user. Beacuse I
want
to pick up which logged on user it is to log the actions.
My application is used on intranet only, and I dont allow anonymous
access.
This is an update to my application, I used to have a VB6 component
that sent email using CDO, and that worked fine.

/Robert
"GrantMagic" <gr***@magicalia.com> wrote in message
news:eP**************@TK2MSFTNGP11.phx.gbl...
AS well as setting "identity impersonate" to true, did you set which user

to
impersonate.

i.e.
<identity impersonate="true" userName="DMN\UserName" password="password"

/>

"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:OT**************@TK2MSFTNGP09.phx.gbl...
> Hi,
>
> I have built an webapp in C# that uses SMTPMail to send mail to users.
> When I installed it on the prodserver everything worked fine for me,
> but
> the
> users can not send mail.
> They get Access denied. If I add them to the administrator group of the
> server everything works fine.
>
> I have set
> <identity impersonate="true"/>
> in my web.config.
>
> And tried to add users in my local SMTP Virtuall Server.
> But Im using an external Exchange as my SMTP server in my code.
>
> Is there anything else I need to do to let the users send email? I read
> that
> I need
> to grant permissions in tha ACL(?), for users to send emails i ASP.NET?
>
> Would be very greateful if anyone could help me!!
>
> /Robert Pettersson
>
>



Nov 18 '05 #5

P: n/a
It looks like you require authentication to send message using the Exchange
server ?

AFAIK in .NET 1.1 you can do that using the "fields" property.
http://blogs.bartdesmet.net/bart/arc...04/21/257.aspx

It doesn't have to be the user account. It could be a specific "service"
account...

Patrice

--

"Robert Pettersson" <ro****@carnegie.se> a crit dans le message de
news:OT**************@TK2MSFTNGP09.phx.gbl...
Hi,

I have built an webapp in C# that uses SMTPMail to send mail to users.
When I installed it on the prodserver everything worked fine for me, but the users can not send mail.
They get Access denied. If I add them to the administrator group of the
server everything works fine.

I have set
<identity impersonate="true"/>
in my web.config.

And tried to add users in my local SMTP Virtuall Server.
But Im using an external Exchange as my SMTP server in my code.

Is there anything else I need to do to let the users send email? I read that I need
to grant permissions in tha ACL(?), for users to send emails i ASP.NET?

Would be very greateful if anyone could help me!!

/Robert Pettersson

Nov 18 '05 #6

P: n/a

I had to give permissions to the Temporary ASP.Net Files Dir.

Then the impersination worked, and the mail worked.

Thanks for the help.

Really appreciate it!

/Robert

"GrantMagic" <gr***@magicalia.com> wrote in message
news:O%****************@TK2MSFTNGP11.phx.gbl...
impersonating a user will not change which user is logging the actions, that should be handeled within the application. Impersonating a user will merely impersonate that user for actions on the server .. like sending the mail.
In you application you can then log which user sent the mail, or speficy
that in the from address.

If this solution is still viable for you, then about that error:
Is the user your impersonating an administrator on the server?
Have you tried restarting IIS?
If that fails, post a question of search on Google

Hope this can help you out

Grant

"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:eE**************@TK2MSFTNGP11.phx.gbl...

When I try to set a specific user I get a error:

Access to the path "C:\WINNT\Microsoft.NET\Framework\v1.1.4322\Tempor ary
ASP.NET Files\internalfundtrades\8b42c84e\34a38a07\hash.we b" is denied.

But I dont really want the user to impersonate another user. Beacuse I
want
to pick up which logged on user it is to log the actions.
My application is used on intranet only, and I dont allow anonymous
access.
This is an update to my application, I used to have a VB6 component
that sent email using CDO, and that worked fine.

/Robert
"GrantMagic" <gr***@magicalia.com> wrote in message
news:eP**************@TK2MSFTNGP11.phx.gbl...
AS well as setting "identity impersonate" to true, did you set which user
to
impersonate.

i.e.
<identity impersonate="true" userName="DMN\UserName"
password="password" />

"Robert Pettersson" <ro****@carnegie.se> wrote in message
news:OT**************@TK2MSFTNGP09.phx.gbl...
> Hi,
>
> I have built an webapp in C# that uses SMTPMail to send mail to

users. > When I installed it on the prodserver everything worked fine for me,
> but
> the
> users can not send mail.
> They get Access denied. If I add them to the administrator group of the > server everything works fine.
>
> I have set
> <identity impersonate="true"/>
> in my web.config.
>
> And tried to add users in my local SMTP Virtuall Server.
> But Im using an external Exchange as my SMTP server in my code.
>
> Is there anything else I need to do to let the users send email? I read > that
> I need
> to grant permissions in tha ACL(?), for users to send emails i ASP.NET? >
> Would be very greateful if anyone could help me!!
>
> /Robert Pettersson
>
>



Nov 18 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.