[3.0] Change vulnerable function 'strcpy' to 'strncpy' for better security 00/89700/1
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Mon, 26 Sep 2016 06:20:51 +0000 (15:20 +0900)
committerSeoyeon Kim <seoyeon2.kim@samsung.com>
Mon, 26 Sep 2016 11:14:06 +0000 (20:14 +0900)
Change-Id: I57a0c89b91f4152b9e2160e61ba3077619384c68
Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
adaptors/ecore/wayland/clipboard-impl-ecore-wl.cpp

index 1744b2d..aad03a3 100644 (file)
@@ -94,7 +94,7 @@ struct Clipboard::Impl
     {
       return;
     }
-    strcpy(mSendBuf, data);
+    strncpy(mSendBuf, data, CLIPBOARD_BUFFER_SIZE);
 
     // ELM_SEL_TYPE_CLIPBOARD - To distinguish clipboard selection in cbhm
     types[++i] = "CLIPBOARD_BEGIN";