cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Visitor
Visitor
2,533 Views
Registered: ‎03-12-2018

BuG: Vivado: shared objects are not executable and should *not* have +x flag

 

See:

 

    cd {{vivado_prefix}} && find -type f -executable -name "*.so*"

 

ELF shared objects are not executable and therefore shall not have +x flag set.

The +x flag is meant only for files which can be directly loaded/executed via exec*() syscalls.

 

Tags (3)
0 Kudos
8 Replies
Highlighted
Scholar
Scholar
2,501 Views
Registered: ‎03-22-2016

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

@metux Oh wow. This is a horrible bug. Just imagine if someone executes a shared library by accident.

Thanks for reporting.

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos
Highlighted
Moderator
Moderator
2,383 Views
Registered: ‎11-09-2015

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

Hi @metux,

 

I general, this is not an issue for most files.  For example, if someone attempts to execute a readme file, nothing will happen even though it has x permissions.  Giving x permission is a system default and unless the umask is set to turn it off or Xilinx explicitly turns it off for a specific file it will be set.  Xilinx does not typically restrict any file permissions unless there is a need.


Florent
Product Application Engineer - Xilinx Technical Support EMEA
**~ Don't forget to reply, give kudos, and accept as solution.~**
0 Kudos
Highlighted
Visitor
Visitor
2,340 Views
Registered: ‎03-12-2018

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

> I general, this is not an issue for most files.  For example, if someone attempts to execute a readme file, nothing will happen even

> though it has x permissions

 

Okay, if you really believe that, then just execute the attached Readme file.

 

> Giving x permission is a system default and unless the umask is set to turn it off 

 

No, it's not. The Linux kernel doesn't automatically set +x on non-directories even w/ umask=0 - you'll have explicitly chmod() it.

And distros set the umask to some sane value (eg. 022, or 002 when using per-user groups) - see /etc/login.defs.

 

I'd suggest making yourself confident w/ the essiential basics of the operating system.

https://www.amazon.de/Linux-Pocket-Guide-Daniel-Barrett/dp/1491927577/ref=pd_cp_14_3?_encoding=UTF8&psc=1&refRID=TD8P9Q4H1G5YGCD9GY4F

0 Kudos
Highlighted
Scholar
Scholar
2,326 Views
Registered: ‎03-22-2016

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

@metux 

I am confused. Are you saying there is harmful code in text files distributed with vivado?

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos
Highlighted
Visitor
Visitor
2,318 Views
Registered: ‎03-12-2018

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

Haven't checked everything ... but there easily can be if arbitrary text/data is interpreted as a script. That's exactly the reason why the x flags exist.

 

EDIT: and that's exactly the reason why the kernel doesn't set the +x flag automatically.

0 Kudos
Highlighted
Scholar
Scholar
2,309 Views
Registered: ‎03-22-2016

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

Very unlikely. I have submitted Vivado to Amazon and they have a super strict quality control with several anti-virus and security checks. They never caught anything. 

 

If these files had setuid set, I would be concerned though.

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
Highlighted
Visitor
Visitor
2,267 Views
Registered: ‎03-12-2018

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

> I have submitted Vivado to Amazon and they have a super strict quality control with several anti-virus and security checks. They

> never caught anything. 

 

Anti-Virus. *LOL*

 

> If these files had setuid set, I would be concerned though.

 
I never talked about setuid - that's a whole different topic.
 
0 Kudos
Highlighted
Scholar
Scholar
2,250 Views
Registered: ‎03-22-2016

Re: BuG: Vivado: shared objects are not executable and should *not* have +x flag

@metux this type of language is perhaps more appropriate to a teenager on Reddit. Be professional. 

 

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos