Is there a way to prevent copying in Gerrit diff view?

44 views
Skip to first unread message

euni...@gmail.com

unread,
Dec 10, 2017, 8:00:39 PM12/10/17
to Repo and Gerrit Discussion
Hello!!

Is there a way to prevent copying from Gerrit web with read permission granted?


Thank you!

Dave Borowitz

unread,
Dec 11, 2017, 2:51:12 PM12/11/17
to euni...@gmail.com, Repo and Gerrit Discussion
We don't have anything like that built into Gerrit currently, but I imagine it's technically feasible.

I have to point out, though, that this would accomplish nothing to make your code more secure. Anybody who can view code in the web UI can by definition also fetch that code with "git fetch".

--
--
To unsubscribe, email repo-discuss+unsubscribe@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

euni...@gmail.com

unread,
Jan 5, 2018, 12:49:03 AM1/5/18
to Repo and Gerrit Discussion
Thank you for reply.

Sorry for the late reply.

I should prohibit the drag from the diff screen.
So I want to add the following script, which file should I access?

<script language="javascript1.2">
function disableselect(e){
return false
}
function reEnable(){
return true
}
document.onselectstart=new Function ("return false")
if (window.sidebar){
document.onmousedown=disableselect
document.onclick=reEnable
}
</script>
Reply all
Reply to author
Forward
0 new messages