Go Back   Forum Care Forums > Development Reference Area > Webmaster Topics

Reply
 
LinkBack Thread Tools Display Modes
Need help with securing scripts from users
Old
  (#1)
John Small
Guest
 
Posts: n/a
Default Need help with securing scripts from users - 05-14-2007, 01:27 AM

I am working on implementing a email-through-a-form solution to spam
avoidance.

I have a PHP script that works and I have the recipient email
addresses embedded in the script (i.e. not in the HTML page). So I
would like be able to prevent any users (especially spambots) from
being able to read the script.

In my limited testing I have not been able to get a browser to view
the PHP file. Nor have I been able to retrieve the PHP file with
anonymous FTP. But I know I am not nearly imformed or clever enough to
believe that I have "proven" that the script is sufficiently secure.

Are there certain directories I should or should not use? Are there
file permissions that I should use or should not use? Is having a
"guessable" filename an issue? Is PHP OK for this purpose or should I
look at another type of script?

Please tell me (or point me to) what I need to do to secure this
script from prying eyes?

Any help will be appreciated.

--

John Small

(remove the z's for email address)
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote

Re: Need help with securing scripts from users
Old
  (#2)
Rik
Guest
 
Posts: n/a
Default Re: Need help with securing scripts from users - 05-14-2007, 01:27 AM

John Small wrote:
> I am working on implementing a email-through-a-form solution to spam
> avoidance.
>
> I have a PHP script that works and I have the recipient email
> addresses embedded in the script (i.e. not in the HTML page). So I
> would like be able to prevent any users (especially spambots) from
> being able to read the script.
>
> In my limited testing I have not been able to get a browser to view
> the PHP file. Nor have I been able to retrieve the PHP file with
> anonymous FTP. But I know I am not nearly imformed or clever enough to
> believe that I have "proven" that the script is sufficiently secure.
>
> Are there certain directories I should or should not use? Are there
> file permissions that I should use or should not use? Is having a
> "guessable" filename an issue? Is PHP OK for this purpose or should I
> look at another type of script?
>
> Please tell me (or point me to) what I need to do to secure this
> script from prying eyes?


As long as the server is configured correctly, noone will ever be able to
retrieve the target emailadress.
A point for security though, is header injection.
http://www.securephpwiki.com/index.php/Email_Injection
--
Rik Wasmus


   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Re: Need help with securing scripts from users
Old
  (#3)
Toby Inkster
Guest
 
Posts: n/a
Default Re: Need help with securing scripts from users - 05-14-2007, 01:27 AM

John Small wrote:

> In my limited testing I have not been able to get a browser to view
> the PHP file.


Yep -- that's the way PHP works (and indeed all server-side scripting).
The server never sends the PHP file to the browser -- it only sends the
results of processing the file.

--
Toby A Inkster BSc (Hons) ARCS
Contact Me ~ http://tobyinkster.co.uk/contact

   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Re: Need help with securing scripts from users
Old
  (#4)
Charles Sweeney
Guest
 
Posts: n/a
Default Re: Need help with securing scripts from users - 05-14-2007, 01:27 AM

John Small wrote

> I am working on implementing a email-through-a-form solution to spam
> avoidance.
>
> I have a PHP script that works and I have the recipient email
> addresses embedded in the script (i.e. not in the HTML page). So I
> would like be able to prevent any users (especially spambots) from
> being able to read the script.
>
> In my limited testing I have not been able to get a browser to view
> the PHP file. Nor have I been able to retrieve the PHP file with
> anonymous FTP. But I know I am not nearly imformed or clever enough to
> believe that I have "proven" that the script is sufficiently secure.
>
> Are there certain directories I should or should not use? Are there
> file permissions that I should use or should not use? Is having a
> "guessable" filename an issue? Is PHP OK for this purpose or should I
> look at another type of script?
>
> Please tell me (or point me to) what I need to do to secure this
> script from prying eyes?
>
> Any help will be appreciated.


In agreement with the other replies. An unguessable name never goes
wrong.

--
Charles Sweeney
http://CharlesSweeney.com
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Re: Need help with securing scripts from users
Old
  (#5)
GreyWyvern
Guest
 
Posts: n/a
Default Re: Need help with securing scripts from users - 05-14-2007, 01:27 AM

And lo, Charles Sweeney didst speak in alt.www.webmaster:

> John Small wrote
>
>> Any help will be appreciated.

>
> In agreement with the other replies. An unguessable name never goes
> wrong.


Fat lot of good it did for Rumplestiltskin.

Grey

--
The technical axiom that nothing is impossible sinisterly implies the
pitfall corollary that nothing is ridiculous.
- http://www.greywyvern.com/orca#search - Orca Search: Full-featured
spider and site-search engine
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Re: Need help with securing scripts from users
Old
  (#6)
Charles Sweeney
Guest
 
Posts: n/a
Default Re: Need help with securing scripts from users - 05-14-2007, 01:27 AM

GreyWyvern wrote

> And lo, Charles Sweeney didst speak in alt.www.webmaster:
>
>> John Small wrote
>>
>>> Any help will be appreciated.

>>
>> In agreement with the other replies. An unguessable name never goes
>> wrong.

>
> Fat lot of good it did for Rumplestiltskin.


lol!

--
Charles Sweeney
http://CharlesSweeney.com
   
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On





Contact Us - Forum Care Forums - Archive - Top