Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
23826a28
Kaydet (Commit)
23826a28
authored
Tem 26, 2012
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
use EDB as well as CVE as encrypted prefixes
Change-Id: I3cb1e4d736ca1627cb0716a9c17ff11b5a837264
üst
2584a460
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
7 deletions
+13
-7
filters-test.hxx
unotest/inc/unotest/filters-test.hxx
+3
-2
filters-test.cxx
unotest/source/cpp/filters-test.cxx
+10
-5
No files found.
unotest/inc/unotest/filters-test.hxx
Dosyayı görüntüle @
23826a28
...
...
@@ -40,8 +40,9 @@ enum filterStatus
};
/*
* NOTE, any files beginning with CVE- will be assumed to be encrypted using
* arcfour with key 0x435645, this is to silence panicky virus/malware-checkers
* NOTE, any files beginning with CVE- or EDB- will be assumed to be encrypted
* using arcfour with key 0x435645, this is to silence panicky
* virus/malware-checkers
*
* e.g. m[de]crypt --bare -a arcfour -o hex -k 435645 -s 3
*/
...
...
unotest/source/cpp/filters-test.cxx
Dosyayı görüntüle @
23826a28
...
...
@@ -87,7 +87,7 @@ void FiltersTest::recursiveScan(const rtl::OUString &rFilter, const rtl::OUStrin
else
{
rtl
::
OUString
sTmpFile
;
bool
b
CVE
=
false
;
bool
b
Encrypted
=
false
;
sal_Int32
nLastSlash
=
sURL
.
lastIndexOf
(
'/'
);
...
...
@@ -97,14 +97,19 @@ void FiltersTest::recursiveScan(const rtl::OUString &rFilter, const rtl::OUStrin
if
(
sURL
.
getStr
()[
nLastSlash
+
1
]
==
'.'
)
continue
;
if
(
sURL
.
matchAsciiL
(
RTL_CONSTASCII_STRINGPARAM
(
"CVE"
),
nLastSlash
+
1
))
bCVE
=
true
;
if
(
(
sURL
.
matchAsciiL
(
RTL_CONSTASCII_STRINGPARAM
(
"CVE"
),
nLastSlash
+
1
))
||
(
sURL
.
matchAsciiL
(
RTL_CONSTASCII_STRINGPARAM
(
"EDB"
),
nLastSlash
+
1
))
)
{
bEncrypted
=
true
;
}
}
rtl
::
OString
aRes
(
rtl
::
OUStringToOString
(
sURL
,
osl_getThreadTextEncoding
()));
if
(
b
CVE
)
if
(
b
Encrypted
)
{
CPPUNIT_ASSERT
(
osl
::
FileBase
::
E_None
==
osl
::
FileBase
::
createTempFile
(
NULL
,
NULL
,
&
sTmpFile
));
decode
(
sURL
,
sTmpFile
);
...
...
@@ -118,7 +123,7 @@ void FiltersTest::recursiveScan(const rtl::OUString &rFilter, const rtl::OUStrin
bool
bRes
=
load
(
rFilter
,
sURL
,
rUserData
);
sal_uInt32
nEndTime
=
osl_getGlobalTimer
();
if
(
b
CVE
)
if
(
b
Encrypted
)
CPPUNIT_ASSERT
(
osl
::
FileBase
::
E_None
==
osl
::
File
::
remove
(
sTmpFile
));
fprintf
(
stderr
,
"%s,%"
SAL_PRIuUINT32
"
\n
"
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment