%global TZ_SYS_ETC %{?TZ_SYS_ETC:%TZ_SYS_ETC}%{!?TZ_SYS_ETC:/opt/etc}
%global TZ_SYS_SHARE %{?TZ_SYS_SHARE:%TZ_SYS_SHARE}%{!?TZ_SYS_SHARE:/opt/share}
%global TZ_SYS_RO_SHARE %{?TZ_SYS_RO_SHARE:%TZ_SYS_RO_SHARE}%{!?TZ_SYS_RO_SHARE:%_datadir}
-%global TZ_SYS_RW_APP %{?TZ_SYS_RW_APP:%TZ_SYS_RW_APP}%!?TZ_SYS_RW_APP:/opt/usr/apps}
+%global TZ_SYS_RW_APP %{?TZ_SYS_RW_APP:%TZ_SYS_RW_APP}%{!?TZ_SYS_RW_APP:/opt/usr/apps}
%global TZ_SYS_CA_CERTS %{?TZ_SYS_CA_CERTS:%TZ_SYS_CA_CERTS}%{!?TZ_SYS_CA_CERTS:%TZ_SYS_ETC/ssl/certs}
%global TZ_SYS_RO_CA_CERTS_ORIG %{?TZ_SYS_RO_CA_CERTS_ORIG:%TZ_SYS_RO_CA_CERTS_ORIG}%{!?TZ_SYS_CA_RO_CERTS_ORGIN:%TZ_SYS_RO_SHARE/ca-certificates/certs}
resource/wgt_negative_certificate
resource/wgt_partner
resource/wgt_platform
+ resource/wgt_positive_link
+ resource/wgt_negative_link
resource/tpk
resource/attacked-tpk
resource/tpk-with-userdata
--- /dev/null
+<Signature xmlns="http://www.w3.org/2000/09/xmldsig#" Id="AuthorSignature">
+<SignedInfo>
+<CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></CanonicalizationMethod>
+<SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"></SignatureMethod>
+<Reference URI="config.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>3tBypO7GkqT8R7QzlWtIHR1vTTBV8+U2/iNt6xCTHWY=</DigestValue>
+</Reference>
+<Reference URI="css%2Fstyle.css">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>Yc5/Km/O7fXXLzDC0Xc34K+k00+3OFIEkRFZXNT7pAI=</DigestValue>
+</Reference>
+<Reference URI="icon.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="images%2Ftizen_32.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>eDr9ZPFlGlapLDnI1BiALwqovNdBvx3Aspc/lWOH3WI=</DigestValue>
+</Reference>
+<Reference URI="index.html">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>vK73PtP7FGlsIb2sihFvwAJX+Ks+GVb8TmdIxtcPGAA=</DigestValue>
+</Reference>
+<Reference URI="js%2Fmain.js">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>w1nM4fGtFaoLC3nYKx+3P5twAWunve6foHDsA5kJReY=</DigestValue>
+</Reference>
+<Reference URI="outboundLink">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="#prop">
+<Transforms>
+<Transform Algorithm="http://www.w3.org/2006/12/xml-c14n11"></Transform>
+</Transforms>
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>lpo8tUDs054eLlBQXiDPVDVKfw30ZZdtkRs1jd7H5K8=</DigestValue>
+</Reference>
+</SignedInfo>
+<SignatureValue>
+Xi8Z7uZlb5zbpnptgwGCwtxXMSb/ES9tcOJDgHu9htcYZz1iByEdW4DlJB+B9LpmLMWm5iUC/TZ1
+Ly1qUw/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451ufjW0iHRE7WlpR6EvI
+W6TFyZgMpQq+kg4hWl2SBTf3s2VI8Ygz7gj8TMlClg==
+</X509Certificate>
+</X509Data>
+</KeyInfo>
+<Object Id="prop"><SignatureProperties xmlns:dsp="http://www.w3.org/2009/xmldsig-properties"><SignatureProperty Id="profile" Target="#AuthorSignature"><dsp:Profile URI="http://www.w3.org/ns/widgets-digsig#profile"></dsp:Profile></SignatureProperty><SignatureProperty Id="role" Target="#AuthorSignature"><dsp:Role URI="http://www.w3.org/ns/widgets-digsig#role-author"></dsp:Role></SignatureProperty><SignatureProperty Id="identifier" Target="#AuthorSignature"><dsp:Identifier></dsp:Identifier></SignatureProperty></SignatureProperties></Object>
+</Signature>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<widget xmlns:tizen="http://tizen.org/ns/widgets" xmlns="http://www.w3.org/ns/widgets" id="http://yourdomain/Basic" version="1.0.0" viewmodes="maximized">
+ <tizen:application id="ybGx5Tni2z.Basic" package="ybGx5Tni2z" required_version="2.4"/>
+ <content src="index.html"/>
+ <feature name="http://tizen.org/feature/screen.size.all"/>
+ <icon src="icon.png"/>
+ <name>Basic</name>
+ <tizen:profile name="mobile"/>
+</widget>
--- /dev/null
+html,
+body {
+ width: 100%;
+ height: 100%;
+ margin: 0 auto;
+ padding: 0;
+ background-color: #222222;
+ color: #ffffff;
+}
+.page {
+ width: 100%;
+ height: 100%;
+ display: table;
+}
+.contents {
+ display: table-cell;
+ vertical-align: middle;
+ text-align: center;
+ -webkit-tap-highlight-color: transparent;
+}
+#content-text {
+ font-weight: bold;
+ font-size: 5em;
+}
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<html>
+
+<head>
+ <meta charset="utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
+ <meta name="description" content="Tizen Mobile Web Basic Template" />
+
+ <title>Tizen Mobile Web Basic Application</title>
+
+ <link rel="stylesheet" type="text/css" href="css/style.css" />
+ <script src="js/main.js"></script>
+</head>
+
+<body>
+ <div id="main" class="page">
+ <div class="contents">
+ <span id="content-text">Basic</span>
+ </div>
+ </div>
+</body>
+
+</html>
--- /dev/null
+window.onload = function() {
+ // TODO:: Do your initialization job
+
+ // add eventListener for tizenhwkey
+ document.addEventListener('tizenhwkey', function(e) {
+ if (e.keyName === "back") {
+ try {
+ tizen.application.getCurrentApplication().exit();
+ } catch (ignore) {}
+ }
+ });
+
+ // Sample code
+ var mainPage = document.querySelector('#main');
+
+ mainPage.addEventListener("click", function() {
+ var contentText = document.querySelector('#content-text');
+
+ contentText.innerHTML = (contentText.innerHTML === "Basic") ? "Tizen" : "Basic";
+ });
+};
\ No newline at end of file
--- /dev/null
+../wgt_positive_link/icon.png
\ No newline at end of file
--- /dev/null
+<Signature xmlns="http://www.w3.org/2000/09/xmldsig#" Id="DistributorSignature">
+<SignedInfo>
+<CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></CanonicalizationMethod>
+<SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"></SignatureMethod>
+<Reference URI="author-signature.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>216byXwFRY0ycTNU+u3YEocLm4bZ3IZP+Q+GxwvTuKI=</DigestValue>
+</Reference>
+<Reference URI="config.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>3tBypO7GkqT8R7QzlWtIHR1vTTBV8+U2/iNt6xCTHWY=</DigestValue>
+</Reference>
+<Reference URI="css%2Fstyle.css">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>Yc5/Km/O7fXXLzDC0Xc34K+k00+3OFIEkRFZXNT7pAI=</DigestValue>
+</Reference>
+<Reference URI="icon.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="images%2Ftizen_32.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>eDr9ZPFlGlapLDnI1BiALwqovNdBvx3Aspc/lWOH3WI=</DigestValue>
+</Reference>
+<Reference URI="index.html">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>vK73PtP7FGlsIb2sihFvwAJX+Ks+GVb8TmdIxtcPGAA=</DigestValue>
+</Reference>
+<Reference URI="js%2Fmain.js">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>w1nM4fGtFaoLC3nYKx+3P5twAWunve6foHDsA5kJReY=</DigestValue>
+</Reference>
+<Reference URI="outboundLink">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="#prop">
+<Transforms>
+<Transform Algorithm="http://www.w3.org/2006/12/xml-c14n11"></Transform>
+</Transforms>
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>u/jU3U4Zm5ihTMSjKGlGYbWzDfRkGphPPHx3gJIYEJ4=</DigestValue>
+</Reference>
+</SignedInfo>
+<SignatureValue>
+Wa4AWsiNy7QNJfPzl3NLSvF1wUCUvwA4LWero5isjXI4SyoFLLufqgleDNU32G6tvhhKfqkwNcCl
+73VcLWEfA+ku+HwJuPm8Eh5FJMvifvqlmZO7Kt2GLiWKhMKM1firJxlhUHSpf7v1elMeRim3RTqg
+SFuyA/hrMRUcuBENGXg=
+</SignatureValue>
+<KeyInfo>
+<X509Data>
+<X509Certificate>
+MIICmzCCAgQCCQDXI7WLdVZwiTANBgkqhkiG9w0BAQUF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DVQQLDBpUVGl6ZW4gRGlzdHJpYnV0b3IgVGVzdCBDQTEpMCcGA1UEAwwgVGl6ZW4gUHVibGlj
+IERpc3RyaWJ1dG9yIFJvb3QgQ0EwHhcNMTIxMDI5MTMwMjUwWhcNMjIxMDI3MTMwMjUwWjCBjzEL
+MAkGA1UEBhMCS1IxDjAMBgNVBAgMBVN1d29uMQ4wDAYDVQQHDAVTdXdvbjEWMBQGA1UECgwNVGl6
+ZW4gVGVzdCBDQTEiMCAGA1UECwwZVGl6ZW4gRGlzdHJpYnV0b3IgVGVzdCBDQTEkMCIGA1UEAwwb
+VGl6ZW4gUHVibGljIERpc3RyaWJ1dG9yIENBMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDe
+OTS/3nXvkDEmsFCJIvRlQ3RKDcxdWJJp625pFqHdmoJBdV+x6jl1raGK2Y1sp2Gdvpjc/z92yzAp
+bE/UVLPh/tRNZPeGhzU4ejDDm7kzdr2f7Ia0U98K+OoY12ucwg7TYNItj9is7Cj4blGfuMDzd2ah
+2AgnCGlwNwV/pv+uVQIDAQABoxAwDjAMBgNVHRMEBTADAQH/MA0GCSqGSIb3DQEBBQUAA4GBACqJ
+KO33YdoGudwanZIxMdXuxnnD9R6u72ltKk1S4zPfMJJv482CRGCI4FK6djhlsI4i0Lt1SVIJEed+
+yc3qckGm19dW+4xdlkekon7pViEBWuyHw8OWv3RXtTum1+PGHjBJ2eYY4ZKIpz73U/1NC16sTB/0
+VhfnkHwPltmrpYVe
+</X509Certificate>
+</X509Data>
+</KeyInfo>
+<Object Id="prop"><SignatureProperties xmlns:dsp="http://www.w3.org/2009/xmldsig-properties"><SignatureProperty Id="profile" Target="#DistributorSignature"><dsp:Profile URI="http://www.w3.org/ns/widgets-digsig#profile"></dsp:Profile></SignatureProperty><SignatureProperty Id="role" Target="#DistributorSignature"><dsp:Role URI="http://www.w3.org/ns/widgets-digsig#role-distributor"></dsp:Role></SignatureProperty><SignatureProperty Id="identifier" Target="#DistributorSignature"><dsp:Identifier></dsp:Identifier></SignatureProperty></SignatureProperties></Object>
+</Signature>
\ No newline at end of file
--- /dev/null
+<Signature xmlns="http://www.w3.org/2000/09/xmldsig#" Id="AuthorSignature">
+<SignedInfo>
+<CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></CanonicalizationMethod>
+<SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"></SignatureMethod>
+<Reference URI="config.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>3tBypO7GkqT8R7QzlWtIHR1vTTBV8+U2/iNt6xCTHWY=</DigestValue>
+</Reference>
+<Reference URI="css%2Fstyle.css">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>Yc5/Km/O7fXXLzDC0Xc34K+k00+3OFIEkRFZXNT7pAI=</DigestValue>
+</Reference>
+<Reference URI="icon.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="images%2Ftizen_32.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>eDr9ZPFlGlapLDnI1BiALwqovNdBvx3Aspc/lWOH3WI=</DigestValue>
+</Reference>
+<Reference URI="index.html">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>vK73PtP7FGlsIb2sihFvwAJX+Ks+GVb8TmdIxtcPGAA=</DigestValue>
+</Reference>
+<Reference URI="js%2Fmain.js">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>w1nM4fGtFaoLC3nYKx+3P5twAWunve6foHDsA5kJReY=</DigestValue>
+</Reference>
+<Reference URI="link">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="#prop">
+<Transforms>
+<Transform Algorithm="http://www.w3.org/2006/12/xml-c14n11"></Transform>
+</Transforms>
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>lpo8tUDs054eLlBQXiDPVDVKfw30ZZdtkRs1jd7H5K8=</DigestValue>
+</Reference>
+</SignedInfo>
+<SignatureValue>
+e8VhZG2ZtBl3KlJhf/QvnTzwpv1HeTSK9Urkjb+Lx+4PFZWDFgb9UCKSeh1Kc1giUtOkiBVg0bQO
+oO0akHeDXe5qcDWo94ZxWLDbNuCY7A3+lmX/wvSTZxCa8OM024ium+MP8PzRKlcqew0D8gK1785u
+6YSrtpsdmvdnTI9G/Ew=
+</SignatureValue>
+<KeyInfo>
+<X509Data>
+<X509Certificate>
+MIIClTCCAX2gAwIBAgIGAVODJIU1MA0GCSqGSIb3DQEBBQUAMFYxGjAYBgNVBAoMEVRpemVuIEFz
+c29jaWF0aW9uMRowGAYDVQQLDBFUaXplbiBBc3NvY2lhdGlvbjEcMBoGA1UEAwwTVGl6ZW4gRGV2
+ZWxvcGVycyBDQTAeFw0xMjExMDEwMDAwMDBaFw0xOTAxMDEwMDAwMDBaMBExDzANBgNVBAMMBmF1
+dGhvcjCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAqFd1i8Gps0Kb6WIAzCHSB1vbfjVbigOd
+kmOx/ESTS4XHPgA8LfqzjATrsASnCovZjxOkqlBEqENnwHirBAAKFGAfjiJWMrNtpBzpvGWYYe5W
+qqct0AxL8XjmMR2IQo0XjeTMT1MwLf7VsjINYeSiKr0YXDIQvjiHM4zxllfml08CAwEAAaMyMDAw
+DAYDVR0TAQH/BAIwADALBgNVHQ8EBAMCB4AwEwYDVR0lBAwwCgYIKwYBB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54LYhD7gSI1CFSe16pUXfcVR7FhJztRaiGLnCrwBE
+dyTZ248+D4L/qR/D0axb3jcCAwEAAaMQMA4wDAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQUFAAOC
+AQEAnOXXQ/1O/QTDHyrmQDtFziqPY3xWlJBqJtEqXiT7Y+Ljpe66e+Ee/OjQMlZe8gu21/8cKklH
+95RxjopMWCVedXDUbWdvS2+CdyvVW/quT2E0tjqIzXDekUTYwwhlPWlGxvfj3VsxqSFq3p8Brl04
+1Gx5RKAGyKVsMfTLhbbwSWwApuBUxYfcNpKwLWGPXkysu+HctY03OKv4/xKBnVWiN8ex/Sgesi0M
++OBAOMdZMPK32uJBTeKFx1xZgTLIhk45V0hPOomPjZloiv0LSS11eyd451ufjW0iHRE7WlpR6EvI
+W6TFyZgMpQq+kg4hWl2SBTf3s2VI8Ygz7gj8TMlClg==
+</X509Certificate>
+</X509Data>
+</KeyInfo>
+<Object Id="prop"><SignatureProperties xmlns:dsp="http://www.w3.org/2009/xmldsig-properties"><SignatureProperty Id="profile" Target="#AuthorSignature"><dsp:Profile URI="http://www.w3.org/ns/widgets-digsig#profile"></dsp:Profile></SignatureProperty><SignatureProperty Id="role" Target="#AuthorSignature"><dsp:Role URI="http://www.w3.org/ns/widgets-digsig#role-author"></dsp:Role></SignatureProperty><SignatureProperty Id="identifier" Target="#AuthorSignature"><dsp:Identifier></dsp:Identifier></SignatureProperty></SignatureProperties></Object>
+</Signature>
\ No newline at end of file
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<widget xmlns:tizen="http://tizen.org/ns/widgets" xmlns="http://www.w3.org/ns/widgets" id="http://yourdomain/Basic" version="1.0.0" viewmodes="maximized">
+ <tizen:application id="ybGx5Tni2z.Basic" package="ybGx5Tni2z" required_version="2.4"/>
+ <content src="index.html"/>
+ <feature name="http://tizen.org/feature/screen.size.all"/>
+ <icon src="icon.png"/>
+ <name>Basic</name>
+ <tizen:profile name="mobile"/>
+</widget>
--- /dev/null
+html,
+body {
+ width: 100%;
+ height: 100%;
+ margin: 0 auto;
+ padding: 0;
+ background-color: #222222;
+ color: #ffffff;
+}
+.page {
+ width: 100%;
+ height: 100%;
+ display: table;
+}
+.contents {
+ display: table-cell;
+ vertical-align: middle;
+ text-align: center;
+ -webkit-tap-highlight-color: transparent;
+}
+#content-text {
+ font-weight: bold;
+ font-size: 5em;
+}
\ No newline at end of file
--- /dev/null
+<!DOCTYPE html>
+<html>
+
+<head>
+ <meta charset="utf-8" />
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
+ <meta name="description" content="Tizen Mobile Web Basic Template" />
+
+ <title>Tizen Mobile Web Basic Application</title>
+
+ <link rel="stylesheet" type="text/css" href="css/style.css" />
+ <script src="js/main.js"></script>
+</head>
+
+<body>
+ <div id="main" class="page">
+ <div class="contents">
+ <span id="content-text">Basic</span>
+ </div>
+ </div>
+</body>
+
+</html>
--- /dev/null
+window.onload = function() {
+ // TODO:: Do your initialization job
+
+ // add eventListener for tizenhwkey
+ document.addEventListener('tizenhwkey', function(e) {
+ if (e.keyName === "back") {
+ try {
+ tizen.application.getCurrentApplication().exit();
+ } catch (ignore) {}
+ }
+ });
+
+ // Sample code
+ var mainPage = document.querySelector('#main');
+
+ mainPage.addEventListener("click", function() {
+ var contentText = document.querySelector('#content-text');
+
+ contentText.innerHTML = (contentText.innerHTML === "Basic") ? "Tizen" : "Basic";
+ });
+};
\ No newline at end of file
--- /dev/null
+icon.png
\ No newline at end of file
--- /dev/null
+<Signature xmlns="http://www.w3.org/2000/09/xmldsig#" Id="DistributorSignature">
+<SignedInfo>
+<CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#"></CanonicalizationMethod>
+<SignatureMethod Algorithm="http://www.w3.org/2001/04/xmldsig-more#rsa-sha256"></SignatureMethod>
+<Reference URI="author-signature.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>DUh6Bz3owCQr3cyqdh8qDBzhq9lv+4xTBgKoW30/BH4=</DigestValue>
+</Reference>
+<Reference URI="config.xml">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>3tBypO7GkqT8R7QzlWtIHR1vTTBV8+U2/iNt6xCTHWY=</DigestValue>
+</Reference>
+<Reference URI="css%2Fstyle.css">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>Yc5/Km/O7fXXLzDC0Xc34K+k00+3OFIEkRFZXNT7pAI=</DigestValue>
+</Reference>
+<Reference URI="icon.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="images%2Ftizen_32.png">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>eDr9ZPFlGlapLDnI1BiALwqovNdBvx3Aspc/lWOH3WI=</DigestValue>
+</Reference>
+<Reference URI="index.html">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>vK73PtP7FGlsIb2sihFvwAJX+Ks+GVb8TmdIxtcPGAA=</DigestValue>
+</Reference>
+<Reference URI="js%2Fmain.js">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>w1nM4fGtFaoLC3nYKx+3P5twAWunve6foHDsA5kJReY=</DigestValue>
+</Reference>
+<Reference URI="link">
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>1d0oEZHqPn+QzNzGIHwj9ODby6x9ggFs9uOsav6jPNs=</DigestValue>
+</Reference>
+<Reference URI="#prop">
+<Transforms>
+<Transform Algorithm="http://www.w3.org/2006/12/xml-c14n11"></Transform>
+</Transforms>
+<DigestMethod Algorithm="http://www.w3.org/2001/04/xmlenc#sha256"></DigestMethod>
+<DigestValue>u/jU3U4Zm5ihTMSjKGlGYbWzDfRkGphPPHx3gJIYEJ4=</DigestValue>
+</Reference>
+</SignedInfo>
+<SignatureValue>
+mrSCC3LnWsUZSBSt8U4zRMTPEw7OK+D0Na/ckLKxkDK9GoIp4fvrtG+LsTlfJJL9XBR/U/jTwimu
+GqaD7dZtJktYeoxeMoFmoISd3cFuUbTIF8ZHoYF/X2Jds8hrXjdFQhUHFAJFtjeZZDZZ/8md4qcv
+JI5SBPh3JCjnqh1uxKo=
+</SignatureValue>
+<KeyInfo>
+<X509Data>
+<X509Certificate>
+MIICmzCCAgQCCQDXI7WLdVZwiTANBgkqhkiG9w0BAQUFADCBjzELMAkGA1UEBhMCS1IxDjAMBgNV
+BAgMBVN1d29uMQ4wDAYDVQQHDAVTdXdvbjEWMBQGA1UECgwNVGl6ZW4gVGVzdCBDQTEiMCAGA1UE
+CwwZVGl6ZW4gRGlzdHJpYnV0b3IgVGVzdCBDQTEkMCIGA1UEAwwbVGl6ZW4gUHVibGljIERpc3Ry
+aWJ1dG9yIENBMB4XDTEyMTAyOTEzMDMwNFoXDTIyMTAyNzEzMDMwNFowgZMxCzAJBgNVBAYTAktS
+MQ4wDAYDVQQIDAVTdXdvbjEOMAwGA1UEBwwFU3V3b24xFjAUBgNVBAoMDVRpemVuIFRlc3QgQ0Ex
+IjAgBgNVBAsMGVRpemVuIERpc3RyaWJ1dG9yIFRlc3QgQ0ExKDAmBgNVBAMMH1RpemVuIFB1Ymxp
+YyBEaXN0cmlidXRvciBTaWduZXIwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBALtMvlc5hENK
+90ZdA+y66+Sy0enD1gpZDBh5T9RP0oRsptJv5jjNTseQbQi0SZOdOXb6J7iQdlBCtR343RpIEz8H
+mrBy7mSY7mgwoU4EPpp4CTSUeAuKcmvrNOngTp5Hv7Ngf02TTHOLK3hZLpGayaDviyNZB5PdqQd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ltKk1S4zPfMJJv482CRGCI4FK6djhlsI4i0Lt1SVIJEed+
+yc3qckGm19dW+4xdlkekon7pViEBWuyHw8OWv3RXtTum1+PGHjBJ2eYY4ZKIpz73U/1NC16sTB/0
+VhfnkHwPltmrpYVe
+</X509Certificate>
+</X509Data>
+</KeyInfo>
+<Object Id="prop"><SignatureProperties xmlns:dsp="http://www.w3.org/2009/xmldsig-properties"><SignatureProperty Id="profile" Target="#DistributorSignature"><dsp:Profile URI="http://www.w3.org/ns/widgets-digsig#profile"></dsp:Profile></SignatureProperty><SignatureProperty Id="role" Target="#DistributorSignature"><dsp:Role URI="http://www.w3.org/ns/widgets-digsig#role-distributor"></dsp:Role></SignatureProperty><SignatureProperty Id="identifier" Target="#DistributorSignature"><dsp:Identifier></dsp:Identifier></SignatureProperty></SignatureProperties></Object>
+</Signature>
\ No newline at end of file
const std::string TestData::widget_negative_certificate_path = std::string(TESTAPP_RES_DIR) + "apps/wgt_negative_certificate";
const std::string TestData::widget_partner_path = std::string(TESTAPP_RES_DIR) + "apps/wgt_partner";
const std::string TestData::widget_platform_path = std::string(TESTAPP_RES_DIR) + "apps/wgt_platform";
+const std::string TestData::widget_positive_link_path = std::string(TESTAPP_RES_DIR) + "apps/wgt_positive_link";
+const std::string TestData::widget_negative_link_path = std::string(TESTAPP_RES_DIR) + "apps/wgt_negative_link";
const std::string TestData::tpk_path = std::string(TESTAPP_RES_DIR) + "apps/tpk";
const std::string TestData::attacked_tpk_path = std::string(TESTAPP_RES_DIR) + "apps/attacked-tpk";
extern const std::string widget_negative_certificate_path;
extern const std::string widget_partner_path;
extern const std::string widget_platform_path;
+extern const std::string widget_positive_link_path;
+extern const std::string widget_negative_link_path;;
extern const std::string tpk_path;
extern const std::string attacked_tpk_path;
"visibility check failed.");
}
}
+RUNNER_TEST(T00111_positive_wgt_link)
+{
+ SignatureFileInfoSet signatureSet;
+ SignatureFinder signatureFinder(TestData::widget_positive_link_path);
+ RUNNER_ASSERT_MSG(
+ SignatureFinder::NO_ERROR == signatureFinder.find(signatureSet),
+ "SignatureFinder failed");
+
+ for (auto &sig : signatureSet) {
+ SignatureValidator validator(sig);
+ SignatureData data;
+ VCerr result = validator.check(
+ TestData::widget_positive_link_path,
+ true,
+ true,
+ data);
+
+ // this condition is for OCSP Success in signature1.xml
+ if (!data.isAuthorSignature())
+ RUNNER_ASSERT_MSG(result == E_SIG_NONE,
+ "If DT_LNK type point within package, it should be success: "
+ << validator.errorToString(result));
+ }
+}
+
+RUNNER_TEST(T00112_negative_wgt_link)
+{
+ SignatureFileInfoSet signatureSet;
+ SignatureFinder signatureFinder(TestData::widget_negative_link_path);
+ RUNNER_ASSERT_MSG(
+ SignatureFinder::NO_ERROR == signatureFinder.find(signatureSet),
+ "SignatureFinder failed");
+
+ for (auto &sig : signatureSet) {
+ SignatureValidator validator(sig);
+ SignatureData data;
+ VCerr result = validator.check(
+ TestData::widget_negative_link_path,
+ true,
+ true,
+ data);
+
+ if (!data.isAuthorSignature())
+ RUNNER_ASSERT_MSG(result == E_SIG_INVALID_REF,
+ "If DT_LNK type point outside of package, it should be fail: "
+ << validator.errorToString(result));
+ }
+}
+
RUNNER_TEST(T00151_negative_hash_check_ref)
{
SignatureFileInfoSet signatureSet;
*/
/*
* @author Bartlomiej Grzelewski (b.grzelewski@samsung.com)
+ * Sangwan Kwon (sangwan.kwon@samsung.com)
* @file ReferenceValidator.cpp
* @version 1.0
* @brief Compare signature reference list and list of widget file.
#include <errno.h>
#include <fstream>
#include <memory>
+#include <unistd.h>
+#include <limits.h>
#include <pcrecpp.h>
#include <dpl/log/log.h>
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
namespace {
const char *SPECIAL_SYMBOL_CURRENT_DIR = ".";
virtual ~Impl(){}
- Result checkReferences(const SignatureData &signatureData){
+ Result checkReferences(const SignatureData &signatureData)
+ {
const ReferenceSet &refSet = signatureData.getReferenceSet();
ReferenceSet refDecoded;
signatureData.isAuthorSignature());
}
+ Result checkOutbound(const std::string &linkPath, const std::string &appPath)
+ {
+ char resolvedPath[PATH_MAX];
+ if (realpath((appPath + "/" + linkPath).c_str(), resolvedPath) == NULL)
+ return ERROR_READING_LNK;
+
+ std::string linkRealPath(resolvedPath);
+ if (linkRealPath.compare(0, appPath.size(), appPath) == 0)
+ return NO_ERROR;
+ else
+ return ERROR_OUTBOUND_LNK;
+ }
+
private:
int hexToInt(char hex);
std::string decodeProcent(const std::string &path);
closedir(dirp);
return ERROR_REFERENCE_NOT_FOUND;
}
+ } else if (result->d_type == DT_LNK) {
+ std::string linkPath(directory + result->d_name);
+
+ if (referenceSet.end() ==
+ referenceSet.find(linkPath))
+ {
+ LogDebug("Found file : " << (directory + result->d_name));
+ LogError("Unknown ERROR_REFERENCE_NOT_FOUND.");
+ closedir(dirp);
+ return ERROR_REFERENCE_NOT_FOUND;
+ }
+
+ Result ret = checkOutbound(linkPath, m_dirpath);
+ if (ret != NO_ERROR) {
+ LogError("Link file point wrong path");
+ closedir(dirp);
+ return ret;
+ }
} else {
LogError("Unknown file type.");
closedir(dirp);
return m_impl->checkReferences(signatureData);
}
+ReferenceValidator::Result ReferenceValidator::checkOutbound(
+ const std::string &linkPath, const std::string &appPath)
+{
+ return m_impl->checkOutbound(linkPath, appPath);
+}
} // ValidationCore
*/
/*
* @author Bartlomiej Grzelewski (b.grzelewski@samsung.com)
+ * Sangwan Kwon (sangwan.kwon@samsung.com)
* @file ReferenceValidator.h
* @version 1.0
* @brief Compare signature reference list with widget package.
ERROR_READING_DIR,
ERROR_UNSUPPORTED_FILE_TYPE,
ERROR_REFERENCE_NOT_FOUND,
- ERROR_DECODING_URL
+ ERROR_DECODING_URL,
+ ERROR_OUTBOUND_LNK,
+ ERROR_READING_LNK
};
ReferenceValidator(const std::string &dirpath);
virtual ~ReferenceValidator();
Result checkReferences(const SignatureData &signatureData);
+ Result checkOutbound(const std::string &linkPath, const std::string &appPath);
private:
class Impl;