You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "David Capwell (Jira)" <ji...@apache.org> on 2025/03/11 22:46:00 UTC
[jira] [Updated] (CASSANDRA-20431) org.apache.cassandra.io.util.BufferedDataOutputStreamPlus#write(java.nio.ByteBuffer) with a read only ByteBuffer causes the JVM to crash
[ https://issues.apache.org/jira/browse/CASSANDRA-20431?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Capwell updated CASSANDRA-20431:
--------------------------------------
Bug Category: Parent values: Availability(12983)Level 1 values: Process Crash(12992)
Complexity: Low Hanging Fruit
Discovered By: Fuzz Test
Severity: Normal
Status: Open (was: Triage Needed)
> org.apache.cassandra.io.util.BufferedDataOutputStreamPlus#write(java.nio.ByteBuffer) with a read only ByteBuffer causes the JVM to crash
> ----------------------------------------------------------------------------------------------------------------------------------------
>
> Key: CASSANDRA-20431
> URL: https://issues.apache.org/jira/browse/CASSANDRA-20431
> Project: Apache Cassandra
> Issue Type: Bug
> Components: Legacy/Core
> Reporter: David Capwell
> Priority: Normal
>
> This was not found in production, but in testing serializers. A read only ByteBuffer got generated which lead to the following crash dump
> {code}
> --------------- T H R E A D ---------------
> Current thread (0x0000000127009000): JavaThread "main" [_thread_in_vm, id=5635, stack(0x000000016b628000,0x000000016b68b000)]
> Stack: [0x000000016b628000,0x000000016b68b000], sp=0x000000016b688e40, free space=387k
> Native frames: (J=compiled Java code, A=aot compiled Java code, j=interpreted, Vv=VM code, C=native code)
> C [libsystem_platform.dylib+0x3f6c] _platform_memmove+0x1bc
> j jdk.internal.misc.Unsafe.copyMemory0(Ljava/lang/Object;JLjava/lang/Object;JJ)V+0 java.base@11.0.15
> j jdk.internal.misc.Unsafe.copyMemory(Ljava/lang/Object;JLjava/lang/Object;JJ)V+29 java.base@11.0.15
> j sun.misc.Unsafe.copyMemory(Ljava/lang/Object;JLjava/lang/Object;JJ)V+11 jdk.unsupported@11.0.15
> j org.apache.cassandra.utils.FastByteOperations$UnsafeOperations.copy(Ljava/lang/Object;JLjava/lang/Object;JJ)V+36
> j org.apache.cassandra.utils.FastByteOperations$UnsafeOperations.copy(Ljava/lang/Object;J[BII)V+61
> j org.apache.cassandra.utils.FastByteOperations$UnsafeOperations.copy(Ljava/lang/Object;JLjava/nio/ByteBuffer;II)V+22
> j org.apache.cassandra.utils.FastByteOperations$UnsafeOperations.copy(Ljava/nio/ByteBuffer;ILjava/nio/ByteBuffer;II)V+54
> j org.apache.cassandra.utils.FastByteOperations.copy(Ljava/nio/ByteBuffer;ILjava/nio/ByteBuffer;II)V+9
> j org.apache.cassandra.io.util.BufferedDataOutputStreamPlus.write(Ljava/nio/ByteBuffer;)V+117
> j org.apache.cassandra.utils.ByteBufferUtil.writeWithVIntLength(Ljava/nio/ByteBuffer;Lorg/apache/cassandra/io/util/DataOutputPlus;)V+12
> j org.apache.cassandra.service.accord.txn.TxnCondition$Value$2.serialize(Lorg/apache/cassandra/service/accord/txn/TxnCondition$Value;Lorg/apache/cassandra/io/util/DataOutputPlus;Lorg/apache/cassandra/service/accord/serializers/Version;)V+19
> j org.apache.cassandra.service.accord.txn.TxnCondition$Value$2.serialize(Lorg/apache/cassandra/service/accord/txn/TxnCondition;Lorg/apache/cassandra/io/util/DataOutputPlus;Lorg/apache/cassandra/service/accord/serializers/Version;)V+7
> j org.apache.cassandra.service.accord.txn.TxnCondition$1.serialize(Lorg/apache/cassandra/service/accord/txn/TxnCondition;Lorg/apache/cassandra/io/util/DataOutputPlus;Lorg/apache/cassandra/service/accord/serializers/Version;)V+23
> j org.apache.cassandra.service.accord.txn.TxnCondition$1.serialize(Ljava/lang/Object;Lorg/apache/cassandra/io/util/DataOutputPlus;Ljava/lang/Object;)V+10
> j org.apache.cassandra.io.Serializers.testSerde(Lorg/apache/cassandra/io/util/DataOutputBuffer;Lorg/apache/cassandra/io/AsymmetricVersionedSerializer;Ljava/lang/Object;Ljava/lang/Object;)V+18
> j org.apache.cassandra.service.accord.txn.TxnConditionTest.lambda$serde$1(Lorg/apache/cassandra/io/util/DataOutputBuffer;Lorg/apache/cassandra/service/accord/txn/TxnCondition;)V+37
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org