change action of squid -v on squid

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

change action of squid -v on squid

--Ahmad--
Hello folks

i just need to change the action of squid

if i do squid -v it shoes squid version
how about if i want to disable that thing and don’t show the compile options ?

how about if i put other message to be shown ?


cheers
_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: change action of squid -v on squid

Alex Rousskov
On 12/03/2017 02:00 AM, --Ahmad-- wrote:

> if i do squid -v it shoes squid version
> how about if i want to disable that thing and don’t show the compile options ?

For that, you need to

* either modify Squid source code (the details are outside of the
squid-users discussion scope but you may be able to get help on squid-dev)

* or wrap Squid executable into your own wrapper script/program (a
simple sysadmin action not specific to Squid).

FWIW, it is usually pointless to hide squid-v info. Consider double
checking your requirements.


> how about if i put other message to be shown ?

Use --enable-build-info option with Squid ./configure script:


>   --enable-build-info="build info string"
>                           Add an additional string in the output of "squid
>                           -v". Default is not to add anything. If the string
>                           is not specified, tries to determine nick and
>                           revision number of the current bazaar branch

FWIW, using --enable-build-info is the right way to add custom
information to squid-v output.


HTH,

Alex.
_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: change action of squid -v on squid

--Ahmad--
actually i guess its in somewhere in C++ files and i though it gonna be easy .

anyway thanks i will check dev guys 


cheer s

On Dec 3, 2017, at 10:11 PM, Alex Rousskov <[hidden email]> wrote:

--enable-build-info="build info string"


_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: change action of squid -v on squid

Amos Jeffries
Administrator
On 05/12/17 06:21, --Ahmad-- wrote:
> actually i guess its in somewhere in C++ files and i though it gonna be
> easy .
>
> anyway thanks i will check dev guys
>

We two are "the dev guys" for the most part :-P

So my question is *why* are you going to such lengths?

Squid requires root privileges to run from command line. As Alex said it
is usually pointless to hide the -v info, since only the most trusted of
users can see it anyway.

Amos
_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users
Reply | Threaded
Open this post in threaded view
|

Re: change action of squid -v on squid

Yuri Voinov


04.12.2017 23:49, Amos Jeffries пишет:
> On 05/12/17 06:21, --Ahmad-- wrote:
>> actually i guess its in somewhere in C++ files and i though it gonna
>> be easy .
>>
>> anyway thanks i will check dev guys
>>
>
> We two are "the dev guys" for the most part :-P
Indeed :-P
>
> So my question is *why* are you going to such lengths?
>
> Squid requires root privileges to run from command line. As Alex said
> it is usually pointless to hide the -v info, since only the most
> trusted of users can see it anyway.
Exactly :-!
>
> Amos
> _______________________________________________
> squid-users mailing list
> [hidden email]
> http://lists.squid-cache.org/listinfo/squid-users

--
"Some people, when confronted with a problem, think «I know, I'll use regular expressions.» Now they have two problems."
--Jamie Zawinsk

**************************
* C++: Bug to the future *
**************************



_______________________________________________
squid-users mailing list
[hidden email]
http://lists.squid-cache.org/listinfo/squid-users

signature.asc (523 bytes) Download Attachment