- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Hiding perl script.
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-19-2004 10:31 PM
тАО06-19-2004 10:31 PM
Is there any way to hide to perl source code program , so that no one can see the source program.
if i do
# cat secret.p
it shows the script
Thanks in Advance ..
Regards ,
Raj. D.
--------
Solved! Go to Solution.
- Tags:
- Perl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-19-2004 11:30 PM
тАО06-19-2004 11:30 PM
Re: Hiding perl script.
And it has to be executable one .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-20-2004 12:36 AM
тАО06-20-2004 12:36 AM
SolutionMedium answer: man perlcc
Long answer: Only hidable to the people that do not know Perl, because Perl has a very good way of showing the code, even if it is pre-compiled, by decomposing the internal structures, so using Perl's native ways of hiding the source code, you won't be able to, and you should not want to be able to
A better way for what you want is make a very small C program that uses a customized crypt/decrypt method to read encrypted perl scripts, and feeds it (internally) to perl.
/My/ opinion: Perl sources should always be readable, since whatever way you try to hide it will only encourage people like me to find ways to decrypt it, just because Perl is not designed to be hidden.
Very long answer:
--8<---
# perldoc -q 'How can I hide the source for my Perl program?'
Found in /pro/lib/perl5/5.8.3/pod/perlfaq3.pod
How can I hide the source for my Perl program?
Delete it. :-) Seriously, there are a number of (mostly
unsatisfactory) solutions with varying levels of ``secu├п┬┐┬╜
rity''.
First of all, however, you can't take away read permis├п┬┐┬╜
sion, because the source code has to be readable in order
to be compiled and interpreted. (That doesn't mean that a
CGI script's source is readable by people on the web,
though--only by people with access to the filesystem.) So
you have to leave the permissions at the socially friendly
0755 level.
Some people regard this as a security problem. If your
program does insecure things and relies on people not
knowing how to exploit those insecurities, it is not
secure. It is often possible for someone to determine the
insecure things and exploit them without viewing the
source. Security through obscurity, the name for hiding
your bugs instead of fixing them, is little security
indeed.
You can try using encryption via source filters (Starting
from Perl 5.8 the Filter::Simple and Filter::Util::Call
modules are included in the standard distribution), but
any decent programmer will be able to decrypt it. You can
try using the byte code compiler and interpreter described
below, but the curious might still be able to de-compile
it. You can try using the native-code compiler described
below, but crackers might be able to disassemble it.
These pose varying degrees of difficulty to people wanting
to get at your code, but none can definitively conceal it
(true of every language, not just Perl).
It is very easy to recover the source of Perl programs.
You simply feed the program to the perl interpreter and
use the modules in the B:: hierarchy. The B::Deparse mod├п┬┐┬╜
ule should be able to defeat most attempts to hide source.
Again, this is not unique to Perl.
If you're concerned about people profiting from your code,
then the bottom line is that nothing but a restrictive
license will give you legal security. License your soft├п┬┐┬╜
ware and pepper it with threatening statements like ``This
is unpublished proprietary software of XYZ Corp. Your
access to it does not give you permission to use it blah
blah blah.'' We are not lawyers, of course, so you should
see a lawyer if you want to be sure your license's wording
will stand up in court.
-->8---
Enjoy, Have F
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-20-2004 12:53 AM
тАО06-20-2004 12:53 AM
Re: Hiding perl script.
And its going very deep.
Thanks procura. Thanks i got it.
10 points to you.
Regards ,
RVeri.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-22-2004 06:27 PM
тАО06-22-2004 06:27 PM
Re: Hiding perl script.
Please assign those 10 points you want to give.
Regards,
Sri Ram