Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by eventropy · Sep 18, 2013 at 03:31 PM · editordllweb-player

How stupid would it be to allow users to upload dll's for use in my application?

I'm working on a browser based unity game that also has an online editor. It occurred to me that it would be useful for users to be able to add 'plugins' to the editor that I've created. One idea that occurred to me for this was to allow users to upload DLL's with some c sharp classes that add functionality to the editor, and then load the DLL's associated with the current user automatically. My understanding is that the web player runs in a sandbox environment so would prevent the user from uploading code that was all that malicious. And ultimately the DLL is only run on the client machine (and not other users). I've run some tests and have got this basic concept working. But it just strikes me like this is a bad idea somehow. Are there any risks to this approach?

Comment
Add comment · Show 1
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image perchik · Sep 18, 2013 at 04:01 PM 0
Share

Curious! I have the same gut feelings as you, this seems like a bad idea, but I have no proof to back this up.

3 Replies

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by Bunny83 · Sep 18, 2013 at 06:53 PM

There are huge security risks since, even when it's managed code, it can change nearly every aspect and function in the game. Since Reflection can be used even in the webplayer a foreign DLL could do any changes to the game. Of course everything happens inside the sandbox on the client machine, but it allows to change anything within your game.

It's possible to use relfection to analyse the DLL code quite easy, however that requires your game to load the DLL first and at this point it would be too late.

I would recommend to use a scripting language like UniLUA

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image eventropy · Sep 18, 2013 at 07:05 PM 0
Share

That's exactly what I was looking for, thanks.

avatar image
0

Answer by JamieSinn · Sep 18, 2013 at 06:08 PM

Would the changes be cached for that single use only, or for that ip only or would it be saved to the webserver? If it is saved to the webserver, it could very much so be an issue of causing other players greif by adding an extremely hard level/addon or by changing base mechanics. And as you said, malicious files could be uploaded to steal info specifically.

The largest risk is processing power IMO. someone could upload an insanely intensive webserver only script that could lag and crash your server.

I hope i helped

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image eventropy · Sep 18, 2013 at 06:40 PM 0
Share

They could add functionality to their level and once published, their level could be played by other users. So the dll would be saved to the web server, then streamed to any user that opens the new level, which would then execute the dll in the web player on the client machine.

You make a good point that level creators could upload a dll that s$$anonymous$$ls info on its users and sends it to some online database (whatever info it can get from within the unity web player anyway). As you say, it is also a risk that users could make levels unplayable or crash, but that's really their responsibility, that would just be a badly made level. I'd be more worried about security risks.

So far I haven't heard any deal breakers.

avatar image
0

Answer by ashjack · Sep 18, 2013 at 07:38 PM

I don't know if it would work or not, but hiring moderators to check the DLL for malicious code may be a good idea.

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

20 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How to compile Class Library using Visual Studio 1 Answer

Plugin To Extend Editor By DLL which contains Mono behaviours 0 Answers

UnityEditor assembly referenced by third party DLL 0 Answers

Execute editor window scripts when project errors are present 0 Answers

Easier way to handle unloading dlls? 0 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges